Commit a61455cd authored by Siddharth Asthana's avatar Siddharth Asthana Committed by Peter Leitzen

Fix Style/OpenStructUse offenses for users and package specs

Changelog: other
parent 0b096a99
......@@ -43,8 +43,6 @@ Style/OpenStructUse:
- spec/lib/gitlab/quick_actions/command_definition_spec.rb
- spec/models/design_management/design_action_spec.rb
- spec/models/design_management/design_at_version_spec.rb
- spec/models/user_spec.rb
- spec/presenters/packages/nuget/search_results_presenter_spec.rb
- spec/services/packages/nuget/metadata_extraction_service_spec.rb
- spec/services/projects/import_service_spec.rb
- spec/services/system_note_service_spec.rb
......
......@@ -1388,7 +1388,7 @@ RSpec.describe User do
end
describe '#update_tracked_fields!', :clean_gitlab_redis_shared_state do
let(:request) { OpenStruct.new(remote_ip: "127.0.0.1") }
let(:request) { double('request', remote_ip: "127.0.0.1") }
let(:user) { create(:user) }
it 'writes trackable attributes' do
......
......@@ -9,9 +9,9 @@ RSpec.describe Packages::Nuget::SearchResultsPresenter do
let_it_be(:tag2) { create(:packages_tag, package: package_a, name: 'tag2') }
let_it_be(:packages_b) { create_list(:nuget_package, 5, project: project, name: 'DummyPackageB') }
let_it_be(:packages_c) { create_list(:nuget_package, 5, project: project, name: 'DummyPackageC') }
let_it_be(:search_results) { OpenStruct.new(total_count: 3, results: [package_a, packages_b, packages_c].flatten) }
let_it_be(:presenter) { described_class.new(search_results) }
let(:search_results) { double('search_results', total_count: 3, results: [package_a, packages_b, packages_c].flatten) }
let(:presenter) { described_class.new(search_results) }
let(:total_count) { presenter.total_count }
let(:data) { presenter.data }
......
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