diff options
author | Nick Schonning <nschonni@gmail.com> | 2023-02-17 07:36:14 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-17 21:36:14 +0900 |
commit | 37914c8757062194c8da2ede28927fdc177dc140 (patch) | |
tree | 23f3452447a2a0dba7207d4641092c308853c59e | |
parent | 4a1bad2fd8bb267f57fb81ee2e9d29a3cc5f612d (diff) |
Autofix Rubocop Style/MethodCallWithoutArgsParentheses (#23645)
-rw-r--r-- | .rubocop_todo.yml | 8 | ||||
-rw-r--r-- | spec/services/activitypub/process_collection_service_spec.rb | 8 | ||||
-rw-r--r-- | spec/services/fetch_resource_service_spec.rb | 4 |
3 files changed, 6 insertions, 14 deletions
diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index d1d5e0612..1a8bd9471 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -3432,14 +3432,6 @@ Style/MapToHash: Exclude: - 'app/models/status.rb' -# Offense count: 6 -# This cop supports safe autocorrection (--autocorrect). -# Configuration parameters: AllowedMethods, AllowedPatterns. -Style/MethodCallWithoutArgsParentheses: - Exclude: - - 'spec/services/activitypub/process_collection_service_spec.rb' - - 'spec/services/fetch_resource_service_spec.rb' - # Offense count: 17 # This cop supports unsafe autocorrection (--autocorrect-all). # Configuration parameters: EnforcedStyle. diff --git a/spec/services/activitypub/process_collection_service_spec.rb b/spec/services/activitypub/process_collection_service_spec.rb index 093a188a2..a308cede7 100644 --- a/spec/services/activitypub/process_collection_service_spec.rb +++ b/spec/services/activitypub/process_collection_service_spec.rb @@ -212,8 +212,8 @@ RSpec.describe ActivityPub::ProcessCollectionService, type: :service do 'id' => 'https://example.com/users/bob/fake-status' ) ), - anything(), - anything() + anything, + anything ) expect(ActivityPub::Activity).not_to receive(:factory).with( @@ -222,8 +222,8 @@ RSpec.describe ActivityPub::ProcessCollectionService, type: :service do 'content' => '<p>puck was here</p>' ) ), - anything(), - anything() + anything, + anything ) subject.call(json, forwarder) diff --git a/spec/services/fetch_resource_service_spec.rb b/spec/services/fetch_resource_service_spec.rb index c0c96ab69..0c0c306fe 100644 --- a/spec/services/fetch_resource_service_spec.rb +++ b/spec/services/fetch_resource_service_spec.rb @@ -21,7 +21,7 @@ RSpec.describe FetchResourceService, type: :service do context 'when OpenSSL::SSL::SSLError is raised' do before do - request = double() + request = double allow(Request).to receive(:new).and_return(request) allow(request).to receive(:add_headers) allow(request).to receive(:on_behalf_of) @@ -33,7 +33,7 @@ RSpec.describe FetchResourceService, type: :service do context 'when HTTP::ConnectionError is raised' do before do - request = double() + request = double allow(Request).to receive(:new).and_return(request) allow(request).to receive(:add_headers) allow(request).to receive(:on_behalf_of) |