gitlab-org--gitlab-foss/spec/lib/gitlab
Stan Hu ed1d4fa477 Remove user OAuth tokens stored in database for Bitbucket, GitHub, and GitLab
and request them each session. Pass these tokens to the project import data.

This prevents the need to encrypt these tokens and clear them in case they
expire or get revoked.

For example, if you deleted and re-created OAuth2 keys for Bitbucket, you would get
an Error 500 with no way to recover:

```
Started GET "/import/bitbucket/status" for x.x.x.x at 2015-08-07 05:24:10 +0000
Processing by Import::BitbucketController#status as HTML
Completed 500 Internal Server Error in 607ms (ActiveRecord: 2.3ms)

NameError (uninitialized constant Import::BitbucketController::Unauthorized):
  app/controllers/import/bitbucket_controller.rb:77:in `rescue in go_to_bitbucket_for_permissions'
  app/controllers/import/bitbucket_controller.rb:74:in `go_to_bitbucket_for_permissions'
  app/controllers/import/bitbucket_controller.rb:86:in `bitbucket_unauthorized'
```

Closes #1871
2015-08-23 09:23:44 -07:00
..
backend Merge branch 'master' into rubocop-for-tests 2015-06-23 10:44:03 +02:00
bitbucket_import Remove user OAuth tokens stored in database for Bitbucket, GitHub, and GitLab 2015-08-23 09:23:44 -07:00
diff Fix bug where backslashes in inline diffs could be dropped 2015-08-11 18:39:27 -07:00
email No HTML-only email please 2015-08-21 16:09:55 -07:00
github_import Remove user OAuth tokens stored in database for Bitbucket, GitHub, and GitLab 2015-08-23 09:23:44 -07:00
gitlab_import Remove user OAuth tokens stored in database for Bitbucket, GitHub, and GitLab 2015-08-23 09:23:44 -07:00
gitorious_import Make sure user has access to namespace in import tests. 2015-04-15 16:58:43 +02:00
google_code_import Add fixture_file helper. 2015-08-20 12:41:47 -07:00
ldap Remove unnecessary whitespace between let and ( 2015-06-22 14:39:07 +02:00
markdown Remove trailing HTML entities from non-Rinku autolinks as well. 2015-08-20 18:25:16 -07:00
o_auth Fix infinite loop when SAML was incorrectly configured. 2015-08-17 16:39:22 -07:00
asciidoc_spec.rb Fix Style/AlignHash cop violations 2015-06-22 22:24:39 -07:00
auth_spec.rb Change to_not calls to not_to 2015-06-22 12:13:49 +02:00
closing_issue_extractor_spec.rb Fix ClosingIssueExtractor specs 2015-05-26 15:55:26 -04:00
git_access_spec.rb Fix GitAccess. 2015-05-13 09:46:22 +02:00
git_access_wiki_spec.rb Refactor GitAccess to use instance variables. 2015-03-24 14:11:48 +01:00
key_fingerprint_spec.rb Refactor key fingerprint generation. 2015-04-14 12:00:43 +02:00
markup_helper_spec.rb markup_helper: detect .mkd and .mkdn as markdown 2015-08-12 15:29:15 -04:00
note_data_builder_spec.rb Revert "Update noteable after a new note is added" 2015-08-05 12:00:12 +03:00
popen_spec.rb Merge branch 'master' into rubocop-for-tests 2015-06-23 10:44:03 +02:00
project_search_results_spec.rb Add init test for ProjectSearchResults 2015-06-18 10:35:48 -07:00
push_data_builder_spec.rb Extend project web hooks with more data 2015-02-20 10:27:37 -08:00
reference_extractor_spec.rb Revert "Merge branch 'revert-satellites' into 'master' " 2015-08-11 14:33:31 +02:00
regex_spec.rb Fix (project_)name_regex to accept non-ASCII letters and dash 2015-04-27 16:38:47 +02:00
reply_by_email_spec.rb Add stub_reply_by_email_setting helper. 2015-08-20 13:21:22 -07:00
themes_spec.rb Add Gitlab::Themes module; remove Gitlab::Theme 2015-06-13 17:58:16 -04:00
upgrader_spec.rb Update mock and stub syntax for specs 2015-06-22 12:13:46 +02:00
url_builder_spec.rb Added comment notification events to HipChat and Slack services. 2015-03-06 06:54:00 -08:00
version_info_spec.rb Fix Style/TrailingBlankLines cop violations 2015-06-22 14:38:33 -04:00