gitlab-org--gitlab-foss/spec/lib
Rémy Coutable 367b68a01d Merge branch '22348-gitea-importer' into 'master'
It adds a brand new importer for Gitea!

This is a continuation of !6945 started by @bkc.

Gitea aims to be 100% GitHub-compatible but there's a few differences:

- Gitea is not an OAuth provider (yet): https://github.com/go-gitea/gitea/issues/27
  - This means we cannot map Gitea users given an assignee ID => assignees are not set on imported issues and merge requests
- No releases API for now: https://github.com/go-gitea/gitea/issues/330
- API version is `v1` (GitHub is `v3`)
- The IID field for milestones is `id` compared to `number` in GitHub.
- Issues, PRs, milestones, labels don't have a `url` field (the importer now fallback to `''` in that case)

**Known issues:**

- Comments are not imported because comments JSON always have a blank `html_url`/`issue_url`/`pull_request_url`, so the IID cannot be extracted and the issuable cannot be found... :( This is tracked in https://github.com/go-gitea/gitea/issues/401, and solved by https://github.com/gogits/gogs/pull/3624 but this needs to be submitted / merged in Gitea.

This is noted in the documentation.

## Are there points in the code the reviewer needs to double check?

1. I've made `Import::GiteaController` inherit from `Import::GithubController` since both controllers should be identical in the long-term and their current differences are small.
1. I've added a base `IssuableFormatter` class from which `IssueFormatter` & `PullRequestFormatter` inherit
1. I've added shared examples for GitHub/Gitea importer classes
1. I've made `Gitlab::ImportSources` more robust and tested! 🎄 
1. I've added routing specs for import routes! 🎄 

Closes #22348

See merge request !8116
2016-12-20 11:11:24 +00:00
..
banzai Merge branch 'katex-math' into 'master' 2016-12-15 14:11:38 +00:00
bitbucket Add Wiki import to BB importer 2016-12-19 20:48:08 +02:00
ci Convert CI YAML variables keys into strings 2016-12-15 17:05:53 +08:00
constraints Add nested groups support on data level 2016-12-08 11:47:16 +02:00
container_registry
gitlab Merge branch '22348-gitea-importer' into 'master' 2016-12-20 11:11:24 +00:00
json_web_token
mattermost Store mattermost_url in settings 2016-12-17 10:31:14 +01:00
disable_email_interceptor_spec.rb adds second batch of tests changed to active tense 2016-08-09 15:11:39 +01:00
event_filter_spec.rb Add issue events filter and make sure "All" really shows everything 2016-12-04 23:07:22 +01:00
expand_variables_spec.rb Verify expandability of variables defined as part of environment 2016-09-19 10:07:13 +02:00
extracts_path_spec.rb Allow browsing branches that end with '.atom' 2016-10-11 13:31:12 +01:00
file_size_validator_spec.rb
git_ref_validator_spec.rb
gitlab_spec.rb
light_url_builder_spec.rb refactored and added missing spec to light URL builder 2016-11-17 08:22:57 +01:00
repository_cache_spec.rb