diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-10 18:09:23 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-10 18:09:23 +0300 |
commit | dd160c9146069788d76836f9515dba9fd7327a48 (patch) | |
tree | c14dbe07dff64d78b801b5f7aebe2493c4765109 | |
parent | 5ba72f06f23f1ad1d0f428961caf020ccab1e2b2 (diff) |
Add latest changes from gitlab-org/gitlab@master
9 files changed, 16 insertions, 6 deletions
diff --git a/.rubocop_manual_todo.yml b/.rubocop_manual_todo.yml index 34fde35cac5..9a69c96ef00 100644 --- a/.rubocop_manual_todo.yml +++ b/.rubocop_manual_todo.yml @@ -753,9 +753,6 @@ RSpec/EmptyLineAfterFinalLetItBe: - spec/helpers/projects/terraform_helper_spec.rb - spec/helpers/projects_helper_spec.rb - spec/helpers/search_helper_spec.rb - - spec/lib/api/entities/design_management/design_spec.rb - - spec/lib/api/entities/merge_request_changes_spec.rb - - spec/lib/api/entities/release_spec.rb - spec/lib/bulk_imports/groups/loaders/group_loader_spec.rb - spec/lib/extracts_path_spec.rb - spec/lib/extracts_ref_spec.rb @@ -802,9 +799,6 @@ RSpec/EmptyLineAfterFinalLetItBe: - spec/lib/gitlab/hook_data/issue_builder_spec.rb - spec/lib/gitlab/hook_data/merge_request_builder_spec.rb - spec/lib/gitlab/hook_data/release_builder_spec.rb - - spec/lib/gitlab/jira_import/base_importer_spec.rb - - spec/lib/gitlab/jira_import/handle_labels_service_spec.rb - - spec/lib/gitlab/jira_import_spec.rb - spec/lib/gitlab/json_cache_spec.rb - spec/lib/gitlab/language_detection_spec.rb - spec/lib/gitlab/project_search_results_spec.rb diff --git a/changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-api-entities.yml b/changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-api-entities.yml new file mode 100644 index 00000000000..f6451c9ca92 --- /dev/null +++ b/changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-api-entities.yml @@ -0,0 +1,5 @@ +--- +title: Fix EmptyLineAfterFinalLetItBe Rubocop offenses for api entities +merge_request: 58193 +author: Huzaifa Iftikhar @huzaifaiftikhar +type: fixed diff --git a/changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-gitlab-jira-import.yml b/changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-gitlab-jira-import.yml new file mode 100644 index 00000000000..6343b6f0790 --- /dev/null +++ b/changelogs/unreleased/issue-325836-fix-empty-line-after-let-it-be-gitlab-jira-import.yml @@ -0,0 +1,5 @@ +--- +title: Fix EmptyLineAfterFinalLetItBe offenses in spec/lib/gitlab/jira_import +merge_request: 58266 +author: Huzaifa Iftikhar @huzaifaiftikhar +type: fixed diff --git a/spec/lib/api/entities/design_management/design_spec.rb b/spec/lib/api/entities/design_management/design_spec.rb index fe449e3e9bc..fe2b1dadfa7 100644 --- a/spec/lib/api/entities/design_management/design_spec.rb +++ b/spec/lib/api/entities/design_management/design_spec.rb @@ -4,6 +4,7 @@ require 'spec_helper' RSpec.describe API::Entities::DesignManagement::Design do let_it_be(:design) { create(:design) } + let(:entity) { described_class.new(design, request: double) } subject { entity.as_json } diff --git a/spec/lib/api/entities/merge_request_changes_spec.rb b/spec/lib/api/entities/merge_request_changes_spec.rb index f46d8981328..29bfd1da6cc 100644 --- a/spec/lib/api/entities/merge_request_changes_spec.rb +++ b/spec/lib/api/entities/merge_request_changes_spec.rb @@ -5,6 +5,7 @@ require 'spec_helper' RSpec.describe ::API::Entities::MergeRequestChanges do let_it_be(:user) { create(:user) } let_it_be(:merge_request) { create(:merge_request) } + let(:entity) { described_class.new(merge_request, current_user: user) } subject(:basic_entity) { entity.as_json } diff --git a/spec/lib/api/entities/release_spec.rb b/spec/lib/api/entities/release_spec.rb index d57c283c1f4..06062634015 100644 --- a/spec/lib/api/entities/release_spec.rb +++ b/spec/lib/api/entities/release_spec.rb @@ -4,6 +4,7 @@ require 'spec_helper' RSpec.describe API::Entities::Release do let_it_be(:project) { create(:project) } + let(:release) { create(:release, project: project) } let(:evidence) { release.evidences.first } let(:user) { create(:user) } diff --git a/spec/lib/gitlab/jira_import/base_importer_spec.rb b/spec/lib/gitlab/jira_import/base_importer_spec.rb index 1470bad2c4c..9d8143775f9 100644 --- a/spec/lib/gitlab/jira_import/base_importer_spec.rb +++ b/spec/lib/gitlab/jira_import/base_importer_spec.rb @@ -27,6 +27,7 @@ RSpec.describe Gitlab::JiraImport::BaseImporter do context 'when import data exists' do let_it_be(:project) { create(:project) } let_it_be(:jira_import) { create(:jira_import_state, project: project) } + let(:subject) { described_class.new(project) } context 'when #imported_items_cache_key is not implemented' do diff --git a/spec/lib/gitlab/jira_import/handle_labels_service_spec.rb b/spec/lib/gitlab/jira_import/handle_labels_service_spec.rb index 4e2c5afb077..b8c0dc64581 100644 --- a/spec/lib/gitlab/jira_import/handle_labels_service_spec.rb +++ b/spec/lib/gitlab/jira_import/handle_labels_service_spec.rb @@ -10,6 +10,7 @@ RSpec.describe Gitlab::JiraImport::HandleLabelsService do let_it_be(:project_label) { create(:label, project: project, title: 'bug') } let_it_be(:other_project_label) { create(:label, title: 'feature') } let_it_be(:group_label) { create(:group_label, group: group, title: 'dev') } + let(:jira_labels) { %w(bug feature dev group::new) } subject { described_class.new(project, jira_labels).execute } diff --git a/spec/lib/gitlab/jira_import_spec.rb b/spec/lib/gitlab/jira_import_spec.rb index 2b602c80640..94fdff984d5 100644 --- a/spec/lib/gitlab/jira_import_spec.rb +++ b/spec/lib/gitlab/jira_import_spec.rb @@ -9,6 +9,7 @@ RSpec.describe Gitlab::JiraImport do include JiraServiceHelper let_it_be(:project, reload: true) { create(:project) } + let(:additional_params) { {} } subject { described_class.validate_project_settings!(project, **additional_params) } |