diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-07-14 06:09:17 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-07-14 06:09:17 +0300 |
commit | c69e4aa48c55a413b1ae0a7cc2f3537e3bdcdbbd (patch) | |
tree | 3940e30b133af16fa91e0b624c45c3298f71fea9 /spec/requests | |
parent | 804348d39bc1815441c6c4d901a2cf32d5136f9a (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/requests')
5 files changed, 5 insertions, 7 deletions
diff --git a/spec/requests/api/discussions_spec.rb b/spec/requests/api/discussions_spec.rb index c5126dbd1c2..a65dc6e0175 100644 --- a/spec/requests/api/discussions_spec.rb +++ b/spec/requests/api/discussions_spec.rb @@ -30,7 +30,7 @@ RSpec.describe API::Discussions, feature_category: :team_planning do end context 'when noteable is a WorkItem' do - let!(:work_item) { create(:work_item, :issue, project: project, author: user) } + let!(:work_item) { create(:work_item, project: project, author: user) } let!(:work_item_note) { create(:discussion_note_on_issue, noteable: work_item, project: project, author: user) } let(:parent) { project } diff --git a/spec/requests/api/graphql/mutations/issues/update_spec.rb b/spec/requests/api/graphql/mutations/issues/update_spec.rb index e51c057c182..97ead687a82 100644 --- a/spec/requests/api/graphql/mutations/issues/update_spec.rb +++ b/spec/requests/api/graphql/mutations/issues/update_spec.rb @@ -51,9 +51,7 @@ RSpec.describe 'Update of an existing issue', feature_category: :team_planning d expect do post_graphql_mutation(mutation, current_user: current_user) issue.reload - end.to change { issue.work_item_type.base_type }.from('issue').to('incident').and( - change(issue, :issue_type).from('issue').to('incident') - ) + end.to change { issue.work_item_type.base_type }.from('issue').to('incident') end end diff --git a/spec/requests/api/graphql/mutations/notes/create/note_spec.rb b/spec/requests/api/graphql/mutations/notes/create/note_spec.rb index e6feba059c4..37bcdf61d23 100644 --- a/spec/requests/api/graphql/mutations/notes/create/note_spec.rb +++ b/spec/requests/api/graphql/mutations/notes/create/note_spec.rb @@ -105,7 +105,7 @@ RSpec.describe 'Adding a Note', feature_category: :team_planning do context 'as work item' do let_it_be(:project) { create(:project) } - let_it_be(:noteable) { create(:work_item, :issue, project: project) } + let_it_be(:noteable) { create(:work_item, project: project) } context 'when using internal param' do let(:variables_extra) { { internal: true } } diff --git a/spec/requests/api/graphql/mutations/notes/destroy_spec.rb b/spec/requests/api/graphql/mutations/notes/destroy_spec.rb index f40518a574b..9d63eed276d 100644 --- a/spec/requests/api/graphql/mutations/notes/destroy_spec.rb +++ b/spec/requests/api/graphql/mutations/notes/destroy_spec.rb @@ -5,7 +5,7 @@ require 'spec_helper' RSpec.describe 'Destroying a Note', feature_category: :team_planning do include GraphqlHelpers - let(:noteable) { create(:work_item, :issue) } + let(:noteable) { create(:work_item) } let!(:note) { create(:note, noteable: noteable, project: noteable.project) } let(:global_note_id) { GitlabSchema.id_from_object(note).to_s } let(:variables) { { id: global_note_id } } diff --git a/spec/requests/api/graphql/mutations/notes/update/note_spec.rb b/spec/requests/api/graphql/mutations/notes/update/note_spec.rb index 7918bc860fe..7102f817d4c 100644 --- a/spec/requests/api/graphql/mutations/notes/update/note_spec.rb +++ b/spec/requests/api/graphql/mutations/notes/update/note_spec.rb @@ -41,7 +41,7 @@ RSpec.describe 'Updating a Note', feature_category: :team_planning do it_behaves_like 'a Note mutation update only with quick actions' context 'for work item' do - let(:noteable) { create(:work_item, :issue) } + let(:noteable) { create(:work_item) } let(:note) { create(:note, noteable: noteable, project: noteable.project, note: original_body) } it_behaves_like 'a Note mutation updates a note successfully' |