diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-06 00:09:02 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-06 00:09:02 +0300 |
commit | 76623c12c136f43f24c3966ed4b469e2c0b434b7 (patch) | |
tree | 7c5ec884c25e03e4fea131a4d112a9d0ccfd59b8 /spec/models | |
parent | b042382bbf5a4977c5b5c6b0a9a33f4e8ca8d16d (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/models')
-rw-r--r-- | spec/models/ci/build_spec.rb | 4 | ||||
-rw-r--r-- | spec/models/error_tracking/project_error_tracking_setting_spec.rb | 2 | ||||
-rw-r--r-- | spec/models/project_services/jira_service_spec.rb | 6 |
3 files changed, 8 insertions, 4 deletions
diff --git a/spec/models/ci/build_spec.rb b/spec/models/ci/build_spec.rb index f0f6556deec..b99f51bb36e 100644 --- a/spec/models/ci/build_spec.rb +++ b/spec/models/ci/build_spec.rb @@ -3854,6 +3854,10 @@ describe Ci::Build do set(:build) { create(:ci_build, project: project) } let(:path) { 'other_artifacts_0.1.2/another-subdirectory/banana_sample.gif' } + around do |example| + Timecop.freeze { example.run } + end + before do stub_artifacts_object_storage end diff --git a/spec/models/error_tracking/project_error_tracking_setting_spec.rb b/spec/models/error_tracking/project_error_tracking_setting_spec.rb index 5b402e572c3..41630c71f21 100644 --- a/spec/models/error_tracking/project_error_tracking_setting_spec.rb +++ b/spec/models/error_tracking/project_error_tracking_setting_spec.rb @@ -267,7 +267,7 @@ describe ErrorTracking::ProjectErrorTrackingSetting do end it { expect(result[:issue].gitlab_commit).to eq(commit_id) } - it { expect(result[:issue].gitlab_commit_path).to eq("/#{project.namespace.path}/#{project.path}/commit/#{commit_id}") } + it { expect(result[:issue].gitlab_commit_path).to eq("/#{project.namespace.path}/#{project.path}/-/commit/#{commit_id}") } end end diff --git a/spec/models/project_services/jira_service_spec.rb b/spec/models/project_services/jira_service_spec.rb index 6c3da490b08..c573bf7793a 100644 --- a/spec/models/project_services/jira_service_spec.rb +++ b/spec/models/project_services/jira_service_spec.rb @@ -421,7 +421,7 @@ describe JiraService do GlobalID: 'GitLab', relationship: 'mentioned on', object: { - url: "#{Gitlab.config.gitlab.url}/#{project.full_path}/commit/#{commit_id}", + url: "#{Gitlab.config.gitlab.url}/#{project.full_path}/-/commit/#{commit_id}", title: "Solved by commit #{commit_id}.", icon: { title: 'GitLab', url16x16: favicon_path }, status: { resolved: true } @@ -464,7 +464,7 @@ describe JiraService do @jira_service.close_issue(resource, ExternalIssue.new('JIRA-123', project)) expect(WebMock).to have_requested(:post, @comment_url).with( - body: %r{#{custom_base_url}/#{project.full_path}/commit/#{commit_id}} + body: %r{#{custom_base_url}/#{project.full_path}/-/commit/#{commit_id}} ).once end @@ -479,7 +479,7 @@ describe JiraService do @jira_service.close_issue(resource, ExternalIssue.new('JIRA-123', project)) expect(WebMock).to have_requested(:post, @comment_url).with( - body: %r{#{Gitlab.config.gitlab.url}/#{project.full_path}/commit/#{commit_id}} + body: %r{#{Gitlab.config.gitlab.url}/#{project.full_path}/-/commit/#{commit_id}} ).once end |