From be02a1f60a935d5a569b7f0ddb202be0727f71b0 Mon Sep 17 00:00:00 2001 From: rex work Date: Wed, 28 Feb 2024 12:51:54 -0800 Subject: [PATCH] fix rubocop errors --- lib/sidekiq/grouping/adapters/redis_adapter.rb | 9 +++++++-- lib/sidekiq/grouping/adapters/redis_client_adapter.rb | 2 +- lib/sidekiq/grouping/redis.rb | 8 ++++---- spec/modules/batch_spec.rb | 2 +- spec/modules/redis_spec.rb | 2 +- 5 files changed, 14 insertions(+), 9 deletions(-) diff --git a/lib/sidekiq/grouping/adapters/redis_adapter.rb b/lib/sidekiq/grouping/adapters/redis_adapter.rb index b39aaa6..ec1674a 100644 --- a/lib/sidekiq/grouping/adapters/redis_adapter.rb +++ b/lib/sidekiq/grouping/adapters/redis_adapter.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -require_relative "./base_adapter" +require_relative "base_adapter" require_relative "../redis_dispatcher" require_relative "../redis_scripts" @@ -19,7 +19,12 @@ def push_messages(name, messages, remember_unique: false) remember_unique.to_s ] argv = [messages] - redis_call(:evalsha, RedisScripts.script_hash(:merge_array), keys, argv) + redis_call( + :evalsha, + RedisScripts.script_hash(:merge_array), + keys, + argv + ) end def pluck(name, limit) diff --git a/lib/sidekiq/grouping/adapters/redis_client_adapter.rb b/lib/sidekiq/grouping/adapters/redis_client_adapter.rb index e1d3fdf..38e5f82 100644 --- a/lib/sidekiq/grouping/adapters/redis_client_adapter.rb +++ b/lib/sidekiq/grouping/adapters/redis_client_adapter.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -require_relative "./base_adapter" +require_relative "base_adapter" require_relative "../redis_dispatcher" require_relative "../redis_scripts" diff --git a/lib/sidekiq/grouping/redis.rb b/lib/sidekiq/grouping/redis.rb index 6c132bd..5297c44 100644 --- a/lib/sidekiq/grouping/redis.rb +++ b/lib/sidekiq/grouping/redis.rb @@ -1,9 +1,9 @@ # frozen_string_literal: true -require_relative "./redis_dispatcher" -require_relative "./redis_scripts" -require_relative "./adapters/redis_adapter" -require_relative "./adapters/redis_client_adapter" +require_relative "redis_dispatcher" +require_relative "redis_scripts" +require_relative "adapters/redis_adapter" +require_relative "adapters/redis_client_adapter" module Sidekiq module Grouping diff --git a/spec/modules/batch_spec.rb b/spec/modules/batch_spec.rb index 50a4dc9..e86da62 100644 --- a/spec/modules/batch_spec.rb +++ b/spec/modules/batch_spec.rb @@ -2,7 +2,7 @@ require "spec_helper" -describe Sidekiq::Grouping::Batch do +describe Sidekiq::Grouping::Batch do # rubocop:disable RSpec/SpecFilePathFormat subject(:batch_service) { described_class } context "when adding" do diff --git a/spec/modules/redis_spec.rb b/spec/modules/redis_spec.rb index 3c2c38a..5b1ce01 100644 --- a/spec/modules/redis_spec.rb +++ b/spec/modules/redis_spec.rb @@ -2,7 +2,7 @@ require "spec_helper" -describe Sidekiq::Grouping::Redis do +describe Sidekiq::Grouping::Redis do # rubocop:disable RSpec/SpecFilePathFormat include Sidekiq::Grouping::RedisDispatcher subject(:redis_service) { described_class.new }