diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-07-20 18:40:28 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-07-20 18:40:28 +0300 |
commit | b595cb0c1dec83de5bdee18284abe86614bed33b (patch) | |
tree | 8c3d4540f193c5ff98019352f554e921b3a41a72 /spec/requests/jira_authorizations_spec.rb | |
parent | 2f9104a328fc8a4bddeaa4627b595166d24671d0 (diff) |
Add latest changes from gitlab-org/gitlab@15-2-stable-eev15.2.0-rc42
Diffstat (limited to 'spec/requests/jira_authorizations_spec.rb')
-rw-r--r-- | spec/requests/jira_authorizations_spec.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/spec/requests/jira_authorizations_spec.rb b/spec/requests/jira_authorizations_spec.rb index b43d36e94f4..f67288b286b 100644 --- a/spec/requests/jira_authorizations_spec.rb +++ b/spec/requests/jira_authorizations_spec.rb @@ -27,14 +27,16 @@ RSpec.describe 'Jira authorization requests' do redirect_uri: redirect_uri }) oauth_response = json_response + oauth_response_access_token, scope, token_type = oauth_response.values_at('access_token', 'scope', 'token_type') post '/login/oauth/access_token', params: post_data.merge({ code: generate_access_grant.token }) jira_response = response.body + jira_response_access_token = Rack::Utils.parse_nested_query(jira_response)['access_token'] - access_token, scope, token_type = oauth_response.values_at('access_token', 'scope', 'token_type') - expect(jira_response).to eq("access_token=#{access_token}&scope=#{scope}&token_type=#{token_type}") + expect(jira_response).to include("scope=#{scope}&token_type=#{token_type}") + expect(oauth_response_access_token).not_to eql(jira_response_access_token) end context 'when authorization fails' do |