diff options
author | Francisco Javier López <fjlopez@gitlab.com> | 2018-01-12 17:19:13 +0100 |
---|---|---|
committer | Francisco Javier López <fjlopez@gitlab.com> | 2018-01-12 17:19:13 +0100 |
commit | b7c19497822d57993d986c4de685550cc8e39cc7 (patch) | |
tree | 125b007b62e313888d934ba9f8e2ef4feb1d80bb | |
parent | 2c352404ad79559c2e245b4c1b65ba62ab203cdc (diff) | |
download | gitlab-ce-fj-41598-fixing-request-mime-type.tar.gz |
Added regression testfj-41598-fixing-request-mime-type
-rw-r--r-- | spec/lib/gitlab/auth/user_auth_finders_spec.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/lib/gitlab/auth/user_auth_finders_spec.rb b/spec/lib/gitlab/auth/user_auth_finders_spec.rb index 4637816570c..2733eef6611 100644 --- a/spec/lib/gitlab/auth/user_auth_finders_spec.rb +++ b/spec/lib/gitlab/auth/user_auth_finders_spec.rb @@ -76,6 +76,16 @@ describe Gitlab::Auth::UserAuthFinders do expect(find_user_from_rss_token).to be_nil end end + + context 'when the request format is empty' do + it 'the method call does not modify the original value' do + env['action_dispatch.request.formats'] = nil + + find_user_from_rss_token + + expect(env['action_dispatch.request.formats']).to be_nil + end + end end describe '#find_user_from_access_token' do |