diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-26 03:09:21 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-26 03:09:21 +0000 |
commit | 88a161660fc48c4c1a94b51d5c72fdadffc1b1ae (patch) | |
tree | 466b87a16ad25ac602a9b3c5edaaa582f3eddd94 /rubocop | |
parent | 9190fb4bdcb7e1189de69de53a523c5aeff71f91 (diff) | |
download | gitlab-ce-88a161660fc48c4c1a94b51d5c72fdadffc1b1ae.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'rubocop')
-rw-r--r-- | rubocop/cop/avoid_keyword_arguments_in_sidekiq_workers.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/gitlab/change_timzone.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/qa/ambiguous_page_object_name.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/qa/element_with_pattern.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/rspec/env_assignment.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/rspec/factories_in_migration_specs.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/rspec/httparty_basic_auth.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/static_translation_definition.rb | 2 |
8 files changed, 8 insertions, 8 deletions
diff --git a/rubocop/cop/avoid_keyword_arguments_in_sidekiq_workers.rb b/rubocop/cop/avoid_keyword_arguments_in_sidekiq_workers.rb index e1c6a984e75..da3cac073ad 100644 --- a/rubocop/cop/avoid_keyword_arguments_in_sidekiq_workers.rb +++ b/rubocop/cop/avoid_keyword_arguments_in_sidekiq_workers.rb @@ -5,7 +5,7 @@ module RuboCop # Cop that blacklists keyword arguments usage in Sidekiq workers class AvoidKeywordArgumentsInSidekiqWorkers < RuboCop::Cop::Cop MSG = "Do not use keyword arguments in Sidekiq workers. " \ - "For details, check https://github.com/mperham/sidekiq/issues/2372".freeze + "For details, check https://github.com/mperham/sidekiq/issues/2372" OBSERVED_METHOD = :perform def on_def(node) diff --git a/rubocop/cop/gitlab/change_timzone.rb b/rubocop/cop/gitlab/change_timzone.rb index 63e6dd411f3..c30a057d51c 100644 --- a/rubocop/cop/gitlab/change_timzone.rb +++ b/rubocop/cop/gitlab/change_timzone.rb @@ -5,7 +5,7 @@ module RuboCop module Gitlab class ChangeTimezone < RuboCop::Cop::Cop MSG = "Do not change timezone in the runtime (application or rspec), " \ - "it could result in silently modifying other behavior.".freeze + "it could result in silently modifying other behavior." def_node_matcher :changing_timezone?, <<~PATTERN (send (const nil? :Time) :zone= ...) diff --git a/rubocop/cop/qa/ambiguous_page_object_name.rb b/rubocop/cop/qa/ambiguous_page_object_name.rb index 5cd8ea25c87..a4a2c04f61f 100644 --- a/rubocop/cop/qa/ambiguous_page_object_name.rb +++ b/rubocop/cop/qa/ambiguous_page_object_name.rb @@ -19,7 +19,7 @@ module RuboCop class AmbiguousPageObjectName < RuboCop::Cop::Cop include QAHelpers - MESSAGE = "Don't use 'page' as a name for a Page Object. Use `%s` instead.".freeze + MESSAGE = "Don't use 'page' as a name for a Page Object. Use `%s` instead." def_node_matcher :ambiguous_page?, <<~PATTERN (block diff --git a/rubocop/cop/qa/element_with_pattern.rb b/rubocop/cop/qa/element_with_pattern.rb index d48f4725488..d0a42497960 100644 --- a/rubocop/cop/qa/element_with_pattern.rb +++ b/rubocop/cop/qa/element_with_pattern.rb @@ -19,7 +19,7 @@ module RuboCop class ElementWithPattern < RuboCop::Cop::Cop include QAHelpers - MESSAGE = "Don't use a pattern for element, create a corresponding `%s` instead.".freeze + MESSAGE = "Don't use a pattern for element, create a corresponding `%s` instead." def on_send(node) return unless in_qa_file?(node) diff --git a/rubocop/cop/rspec/env_assignment.rb b/rubocop/cop/rspec/env_assignment.rb index 73e108c2232..e3075e7bd90 100644 --- a/rubocop/cop/rspec/env_assignment.rb +++ b/rubocop/cop/rspec/env_assignment.rb @@ -17,7 +17,7 @@ module RuboCop # stub_env('FOO', 'bar') # end class EnvAssignment < RuboCop::Cop::Cop - MESSAGE = "Don't assign to ENV, use `stub_env` instead.".freeze + MESSAGE = "Don't assign to ENV, use `stub_env` instead." def_node_search :env_assignment?, <<~PATTERN (send (const nil? :ENV) :[]= ...) diff --git a/rubocop/cop/rspec/factories_in_migration_specs.rb b/rubocop/cop/rspec/factories_in_migration_specs.rb index 732e0d92bbd..f29bbf68cdc 100644 --- a/rubocop/cop/rspec/factories_in_migration_specs.rb +++ b/rubocop/cop/rspec/factories_in_migration_specs.rb @@ -14,7 +14,7 @@ module RuboCop # let(:users) { table(:users) } # let(:user) { users.create!(name: 'User 1', username: 'user1') } class FactoriesInMigrationSpecs < RuboCop::Cop::Cop - MESSAGE = "Don't use FactoryBot.%s in migration specs, use `table` instead.".freeze + MESSAGE = "Don't use FactoryBot.%s in migration specs, use `table` instead." FORBIDDEN_METHODS = %i[build build_list create create_list attributes_for].freeze def_node_search :forbidden_factory_usage?, <<~PATTERN diff --git a/rubocop/cop/rspec/httparty_basic_auth.rb b/rubocop/cop/rspec/httparty_basic_auth.rb index 529a5808662..c6b52ac9781 100644 --- a/rubocop/cop/rspec/httparty_basic_auth.rb +++ b/rubocop/cop/rspec/httparty_basic_auth.rb @@ -13,7 +13,7 @@ module RuboCop # # good # HTTParty.get(url, basic_auth: { username: 'foo' }) class HTTPartyBasicAuth < RuboCop::Cop::Cop - MESSAGE = "`basic_auth: { user: ... }` does not work - replace `user:` with `username:`".freeze + MESSAGE = "`basic_auth: { user: ... }` does not work - replace `user:` with `username:`" RESTRICT_ON_SEND = %i(get put post delete).freeze diff --git a/rubocop/cop/static_translation_definition.rb b/rubocop/cop/static_translation_definition.rb index 55956d9665b..ac50fd94884 100644 --- a/rubocop/cop/static_translation_definition.rb +++ b/rubocop/cop/static_translation_definition.rb @@ -3,7 +3,7 @@ module RuboCop module Cop class StaticTranslationDefinition < RuboCop::Cop::Cop - MSG = "The text you're translating will be already in the translated form when it's assigned to the constant. When a users changes the locale, these texts won't be translated again. Consider moving the translation logic to a method.".freeze + MSG = "The text you're translating will be already in the translated form when it's assigned to the constant. When a users changes the locale, these texts won't be translated again. Consider moving the translation logic to a method." TRANSLATION_METHODS = %i[_ s_ n_].freeze |