Commit 4617680f authored by Sean McGivern's avatar Sean McGivern

Merge branch '228860-resolve-rspec-emptylineafterletblock-qa' into 'master'

Resolve RSpec/EmptyLineAfterLetBlock Exceptions in QA

See merge request gitlab-org/gitlab!38611
parents 92c30e57 8f9962c3
...@@ -290,22 +290,6 @@ RSpec/ContextWording: ...@@ -290,22 +290,6 @@ RSpec/ContextWording:
RSpec/EmptyLineAfterLetBlock: RSpec/EmptyLineAfterLetBlock:
Enabled: true Enabled: true
Exclude: Exclude:
- 'qa/qa/specs/features/api/3_create/repository/changing_repository_storage_spec.rb'
- 'qa/qa/specs/features/browser_ui/3_create/gitaly/high_availability_spec.rb'
- 'qa/qa/specs/features/browser_ui/3_create/repository/move_project_create_fork_spec.rb'
- 'qa/qa/specs/features/browser_ui/5_package/maven_repository_spec.rb'
- 'qa/qa/specs/features/browser_ui/5_package/npm_registry_spec.rb'
- 'qa/qa/specs/features/browser_ui/6_release/pipeline/parent_child_pipelines_dependent_relationship_spec.rb'
- 'qa/qa/specs/features/browser_ui/6_release/pipeline/parent_child_pipelines_independent_relationship_spec.rb'
- 'qa/qa/specs/features/ee/browser_ui/1_manage/group/group_ldap_sync_spec.rb'
- 'qa/qa/specs/features/ee/browser_ui/3_create/merge_request/add_batch_comments_in_merge_request_spec.rb'
- 'qa/qa/specs/features/ee/browser_ui/3_create/repository/assign_code_owners_spec.rb'
- 'qa/qa/specs/features/ee/browser_ui/3_create/repository/pull_mirroring_over_ssh_with_key_spec.rb'
- 'qa/qa/specs/features/ee/browser_ui/3_create/repository/restrict_push_protected_branch_spec.rb'
- 'qa/qa/specs/features/ee/browser_ui/6_release/multi-project_pipelines_spec.rb'
- 'qa/spec/resource/base_spec.rb'
- 'qa/spec/resource/events/project_spec.rb'
- 'qa/spec/scenario/test/integration/mattermost_spec.rb'
- 'spec/config/object_store_settings_spec.rb' - 'spec/config/object_store_settings_spec.rb'
- 'spec/controllers/boards/issues_controller_spec.rb' - 'spec/controllers/boards/issues_controller_spec.rb'
- 'spec/controllers/groups/milestones_controller_spec.rb' - 'spec/controllers/groups/milestones_controller_spec.rb'
......
...@@ -9,6 +9,7 @@ module QA ...@@ -9,6 +9,7 @@ module QA
project.name = 'gitaly_high_availability' project.name = 'gitaly_high_availability'
end end
end end
let(:initial_file) { 'pushed_to_primary.txt' } let(:initial_file) { 'pushed_to_primary.txt' }
let(:final_file) { 'committed_to_primary.txt' } let(:final_file) { 'committed_to_primary.txt' }
let(:praefect_manager) { Service::PraefectManager.new } let(:praefect_manager) { Service::PraefectManager.new }
......
...@@ -10,6 +10,7 @@ module QA ...@@ -10,6 +10,7 @@ module QA
project.initialize_with_readme = true project.initialize_with_readme = true
end end
end end
let(:fork_project) do let(:fork_project) do
Resource::Fork.fabricate_via_api! do |fork| Resource::Fork.fabricate_via_api! do |fork|
fork.user = user fork.user = user
......
...@@ -15,6 +15,7 @@ module QA ...@@ -15,6 +15,7 @@ module QA
Resource::PersonalAccessToken.fabricate!.access_token Resource::PersonalAccessToken.fabricate!.access_token
end end
let(:project) do let(:project) do
Resource::Project.fabricate_via_api! do |project| Resource::Project.fabricate_via_api! do |project|
project.name = 'maven-package-project' project.name = 'maven-package-project'
......
...@@ -14,6 +14,7 @@ module QA ...@@ -14,6 +14,7 @@ module QA
Resource::PersonalAccessToken.fabricate!.access_token Resource::PersonalAccessToken.fabricate!.access_token
end end
let(:project) do let(:project) do
Resource::Project.fabricate_via_api! do |project| Resource::Project.fabricate_via_api! do |project|
project.name = 'npm-registry-project' project.name = 'npm-registry-project'
......
...@@ -8,6 +8,7 @@ module QA ...@@ -8,6 +8,7 @@ module QA
project.name = 'pipelines-dependent-relationship' project.name = 'pipelines-dependent-relationship'
end end
end end
let!(:runner) do let!(:runner) do
Resource::Runner.fabricate_via_api! do |runner| Resource::Runner.fabricate_via_api! do |runner|
runner.project = project runner.project = project
......
...@@ -8,6 +8,7 @@ module QA ...@@ -8,6 +8,7 @@ module QA
project.name = 'pipeline-independent-relationship' project.name = 'pipeline-independent-relationship'
end end
end end
let!(:runner) do let!(:runner) do
Resource::Runner.fabricate_via_api! do |runner| Resource::Runner.fabricate_via_api! do |runner|
runner.project = project runner.project = project
......
...@@ -58,6 +58,7 @@ module QA ...@@ -58,6 +58,7 @@ module QA
} }
] ]
end end
let(:owner_user) { 'enguser1' } let(:owner_user) { 'enguser1' }
let(:sync_users) { ['ENG User 2', 'ENG User 3'] } let(:sync_users) { ['ENG User 2', 'ENG User 3'] }
...@@ -108,6 +109,7 @@ module QA ...@@ -108,6 +109,7 @@ module QA
} }
] ]
end end
let(:owner_user) { 'hruser1' } let(:owner_user) { 'hruser1' }
let(:sync_users) { ['HR User 2', 'HR User 3'] } let(:sync_users) { ['HR User 2', 'HR User 3'] }
......
...@@ -8,6 +8,7 @@ module QA ...@@ -8,6 +8,7 @@ module QA
project.name = 'project-with-merge-request' project.name = 'project-with-merge-request'
end end
end end
let(:merge_request) do let(:merge_request) do
Resource::MergeRequest.fabricate_via_api! do |merge_request| Resource::MergeRequest.fabricate_via_api! do |merge_request|
merge_request.title = 'This is a merge request' merge_request.title = 'This is a merge request'
......
...@@ -13,6 +13,7 @@ module QA ...@@ -13,6 +13,7 @@ module QA
project.initialize_with_readme = true project.initialize_with_readme = true
end end
end end
let(:branch_name) { 'protected-branch' } let(:branch_name) { 'protected-branch' }
before do before do
......
...@@ -11,6 +11,7 @@ module QA ...@@ -11,6 +11,7 @@ module QA
project_push.commit_message = 'Add README.md' project_push.commit_message = 'Add README.md'
end end
end end
let(:source_project_uri) { source.project.repository_ssh_location.uri } let(:source_project_uri) { source.project.repository_ssh_location.uri }
let(:target_project) do let(:target_project) do
Resource::Project.fabricate_via_api! do |project| Resource::Project.fabricate_via_api! do |project|
......
...@@ -68,6 +68,7 @@ module QA ...@@ -68,6 +68,7 @@ module QA
group.path = "access-to-protected-branch-#{SecureRandom.hex(8)}" group.path = "access-to-protected-branch-#{SecureRandom.hex(8)}"
end end
end end
let(:project) do let(:project) do
Resource::Project.fabricate_via_api! do |resource| Resource::Project.fabricate_via_api! do |resource|
resource.name = 'group-with-access-to-protected-branch' resource.name = 'group-with-access-to-protected-branch'
......
...@@ -12,11 +12,13 @@ module QA ...@@ -12,11 +12,13 @@ module QA
project.name = upstream_project_name project.name = upstream_project_name
end end
end end
let(:downstream_project) do let(:downstream_project) do
Resource::Project.fabricate_via_api! do |project| Resource::Project.fabricate_via_api! do |project|
project.name = downstream_project_name project.name = downstream_project_name
end end
end end
let!(:runner) do let!(:runner) do
Resource::Runner.fabricate_via_api! do |runner| Resource::Runner.fabricate_via_api! do |runner|
runner.project = upstream_project runner.project = upstream_project
......
...@@ -226,6 +226,7 @@ describe QA::Resource::Base do ...@@ -226,6 +226,7 @@ describe QA::Resource::Base do
end end
end end
end end
let(:first_resource) do let(:first_resource) do
Class.new(base) do Class.new(base) do
attribute :test do attribute :test do
...@@ -233,6 +234,7 @@ describe QA::Resource::Base do ...@@ -233,6 +234,7 @@ describe QA::Resource::Base do
end end
end end
end end
let(:second_resource) do let(:second_resource) do
Class.new(base) do Class.new(base) do
attribute :test do attribute :test do
......
...@@ -8,6 +8,7 @@ describe QA::Resource::Events::Project do ...@@ -8,6 +8,7 @@ describe QA::Resource::Events::Project do
end end
end end
end end
let(:all_events) do let(:all_events) do
[ [
{ {
......
...@@ -10,6 +10,7 @@ describe QA::Scenario::Test::Integration::Mattermost do ...@@ -10,6 +10,7 @@ describe QA::Scenario::Test::Integration::Mattermost do
mattermost_address: 'http://mattermost_address' mattermost_address: 'http://mattermost_address'
} }
end end
let(:named_options) { %w[--address http://gitlab_address --mattermost-address http://mattermost_address] } let(:named_options) { %w[--address http://gitlab_address --mattermost-address http://mattermost_address] }
let(:tags) { [:mattermost] } let(:tags) { [:mattermost] }
let(:options) { ['path1']} let(:options) { ['path1']}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment