diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-23 18:09:28 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-23 18:09:28 +0300 |
commit | c46b011d3f578d2455443dfabf24226c738c8903 (patch) | |
tree | 89107fa4ccf5340dc14a7d0d2f74a0372e56985f /rubocop | |
parent | b38fc20ae0e90d5b1c538a139aa0a7da1b7b5726 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'rubocop')
-rw-r--r-- | rubocop/cop/gitlab/rails_logger.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/graphql/json_type.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/include_sidekiq_worker.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/lint/last_keyword_argument.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/migration/add_column_with_default.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/migration/add_concurrent_foreign_key.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/migration/add_concurrent_index.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/migration/add_index.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/migration/add_limit_to_text_columns.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/migration/add_timestamps.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/migration/datetime.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/project_path_helper.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/safe_params.rb | 2 | ||||
-rw-r--r-- | rubocop/cop/sidekiq_options_queue.rb | 2 |
14 files changed, 14 insertions, 14 deletions
diff --git a/rubocop/cop/gitlab/rails_logger.rb b/rubocop/cop/gitlab/rails_logger.rb index ad35d2ccfbb..5a1695ce56e 100644 --- a/rubocop/cop/gitlab/rails_logger.rb +++ b/rubocop/cop/gitlab/rails_logger.rb @@ -21,7 +21,7 @@ module RuboCop # # OK # Rails.logger.level MSG = 'Use a structured JSON logger instead of `Rails.logger`. ' \ - 'https://docs.gitlab.com/ee/development/logging.html'.freeze + 'https://docs.gitlab.com/ee/development/logging.html' # See supported log methods: # https://ruby-doc.org/stdlib-2.6.6/libdoc/logger/rdoc/Logger.html diff --git a/rubocop/cop/graphql/json_type.rb b/rubocop/cop/graphql/json_type.rb index 1e3e3d7a7ff..a8c38358535 100644 --- a/rubocop/cop/graphql/json_type.rb +++ b/rubocop/cop/graphql/json_type.rb @@ -20,7 +20,7 @@ module RuboCop module Graphql class JSONType < RuboCop::Cop::Cop MSG = 'Avoid using GraphQL::Types::JSON. See: ' \ - 'https://docs.gitlab.com/ee/development/api_graphql_styleguide.html#json'.freeze + 'https://docs.gitlab.com/ee/development/api_graphql_styleguide.html#json' def_node_matcher :has_json_type?, <<~PATTERN (send nil? {:field :argument} diff --git a/rubocop/cop/include_sidekiq_worker.rb b/rubocop/cop/include_sidekiq_worker.rb index e69bc018add..e39b8bf92c2 100644 --- a/rubocop/cop/include_sidekiq_worker.rb +++ b/rubocop/cop/include_sidekiq_worker.rb @@ -4,7 +4,7 @@ module RuboCop module Cop # Cop that makes sure workers include `ApplicationWorker`, not `Sidekiq::Worker`. class IncludeSidekiqWorker < RuboCop::Cop::Cop - MSG = 'Include `ApplicationWorker`, not `Sidekiq::Worker`.'.freeze + MSG = 'Include `ApplicationWorker`, not `Sidekiq::Worker`.' def_node_matcher :includes_sidekiq_worker?, <<~PATTERN (send nil? :include (const (const nil? :Sidekiq) :Worker)) diff --git a/rubocop/cop/lint/last_keyword_argument.rb b/rubocop/cop/lint/last_keyword_argument.rb index 9652c1ace8d..80f4660eeb8 100644 --- a/rubocop/cop/lint/last_keyword_argument.rb +++ b/rubocop/cop/lint/last_keyword_argument.rb @@ -10,7 +10,7 @@ module RuboCop # 1. Downloading the complete set of deprecations/ files from a CI # pipeline (see https://gitlab.com/gitlab-org/gitlab/-/merge_requests/47720) class LastKeywordArgument < Cop - MSG = 'Using the last argument as keyword parameters is deprecated'.freeze + MSG = 'Using the last argument as keyword parameters is deprecated' DEPRECATIONS_GLOB = File.expand_path('../../../deprecations/**/*.yml', __dir__) KEYWORD_DEPRECATION_STR = 'maybe ** should be added to the call' diff --git a/rubocop/cop/migration/add_column_with_default.rb b/rubocop/cop/migration/add_column_with_default.rb index 355319b0dfe..afd7d93cd47 100644 --- a/rubocop/cop/migration/add_column_with_default.rb +++ b/rubocop/cop/migration/add_column_with_default.rb @@ -8,7 +8,7 @@ module RuboCop class AddColumnWithDefault < RuboCop::Cop::Cop include MigrationHelpers - MSG = '`add_column_with_default` is deprecated, use `add_column` instead'.freeze + MSG = '`add_column_with_default` is deprecated, use `add_column` instead' def on_send(node) return unless in_migration?(node) diff --git a/rubocop/cop/migration/add_concurrent_foreign_key.rb b/rubocop/cop/migration/add_concurrent_foreign_key.rb index 957bd30af63..ebab6aa653e 100644 --- a/rubocop/cop/migration/add_concurrent_foreign_key.rb +++ b/rubocop/cop/migration/add_concurrent_foreign_key.rb @@ -10,7 +10,7 @@ module RuboCop class AddConcurrentForeignKey < RuboCop::Cop::Cop include MigrationHelpers - MSG = '`add_foreign_key` requires downtime, use `add_concurrent_foreign_key` instead'.freeze + MSG = '`add_foreign_key` requires downtime, use `add_concurrent_foreign_key` instead' def_node_matcher :false_node?, <<~PATTERN (false) diff --git a/rubocop/cop/migration/add_concurrent_index.rb b/rubocop/cop/migration/add_concurrent_index.rb index 510f98ce373..bfe7c15bfdf 100644 --- a/rubocop/cop/migration/add_concurrent_index.rb +++ b/rubocop/cop/migration/add_concurrent_index.rb @@ -11,7 +11,7 @@ module RuboCop include MigrationHelpers MSG = '`add_concurrent_index` is not reversible so you must manually define ' \ - 'the `up` and `down` methods in your migration class, using `remove_concurrent_index` in `down`'.freeze + 'the `up` and `down` methods in your migration class, using `remove_concurrent_index` in `down`' def on_send(node) return unless in_migration?(node) diff --git a/rubocop/cop/migration/add_index.rb b/rubocop/cop/migration/add_index.rb index 7415880e554..327e89fb040 100644 --- a/rubocop/cop/migration/add_index.rb +++ b/rubocop/cop/migration/add_index.rb @@ -9,7 +9,7 @@ module RuboCop class AddIndex < RuboCop::Cop::Cop include MigrationHelpers - MSG = '`add_index` requires downtime, use `add_concurrent_index` instead'.freeze + MSG = '`add_index` requires downtime, use `add_concurrent_index` instead' def on_def(node) return unless in_migration?(node) diff --git a/rubocop/cop/migration/add_limit_to_text_columns.rb b/rubocop/cop/migration/add_limit_to_text_columns.rb index 126e4e21f22..f45551e60a4 100644 --- a/rubocop/cop/migration/add_limit_to_text_columns.rb +++ b/rubocop/cop/migration/add_limit_to_text_columns.rb @@ -14,7 +14,7 @@ module RuboCop include MigrationHelpers MSG = 'Text columns should always have a limit set (255 is suggested). ' \ - 'You can add a limit to a `text` column by using `add_text_limit`'.freeze + 'You can add a limit to a `text` column by using `add_text_limit`' def_node_matcher :reverting?, <<~PATTERN (def :down ...) diff --git a/rubocop/cop/migration/add_timestamps.rb b/rubocop/cop/migration/add_timestamps.rb index d16e8b1f45b..01d3f01ef4f 100644 --- a/rubocop/cop/migration/add_timestamps.rb +++ b/rubocop/cop/migration/add_timestamps.rb @@ -9,7 +9,7 @@ module RuboCop class AddTimestamps < RuboCop::Cop::Cop include MigrationHelpers - MSG = 'Do not use `add_timestamps`, use `add_timestamps_with_timezone` instead'.freeze + MSG = 'Do not use `add_timestamps`, use `add_timestamps_with_timezone` instead' # Check methods. def on_send(node) diff --git a/rubocop/cop/migration/datetime.rb b/rubocop/cop/migration/datetime.rb index 51e0c3e5a22..c605c8e1b6e 100644 --- a/rubocop/cop/migration/datetime.rb +++ b/rubocop/cop/migration/datetime.rb @@ -9,7 +9,7 @@ module RuboCop class Datetime < RuboCop::Cop::Cop include MigrationHelpers - MSG = 'Do not use the `%s` data type, use `datetime_with_timezone` instead'.freeze + MSG = 'Do not use the `%s` data type, use `datetime_with_timezone` instead' # Check methods in table creation. def on_def(node) diff --git a/rubocop/cop/project_path_helper.rb b/rubocop/cop/project_path_helper.rb index bc2454e5b1f..ec3f847faf9 100644 --- a/rubocop/cop/project_path_helper.rb +++ b/rubocop/cop/project_path_helper.rb @@ -5,7 +5,7 @@ module RuboCop class ProjectPathHelper < RuboCop::Cop::Cop MSG = 'Use short project path helpers without explicitly passing the namespace: ' \ '`foo_project_bar_path(project, bar)` instead of ' \ - '`foo_namespace_project_bar_path(project.namespace, project, bar)`.'.freeze + '`foo_namespace_project_bar_path(project.namespace, project, bar)`.' METHOD_NAME_PATTERN = /\A([a-z_]+_)?namespace_project(?:_[a-z_]+)?_(?:url|path)\z/.freeze diff --git a/rubocop/cop/safe_params.rb b/rubocop/cop/safe_params.rb index 250c16232e4..2720732c161 100644 --- a/rubocop/cop/safe_params.rb +++ b/rubocop/cop/safe_params.rb @@ -3,7 +3,7 @@ module RuboCop module Cop class SafeParams < RuboCop::Cop::Cop - MSG = 'Use `safe_params` instead of `params` in url_for.'.freeze + MSG = 'Use `safe_params` instead of `params` in url_for.' METHOD_NAME_PATTERN = :url_for UNSAFE_PARAM = :params diff --git a/rubocop/cop/sidekiq_options_queue.rb b/rubocop/cop/sidekiq_options_queue.rb index 499c712175e..2574a229ec2 100644 --- a/rubocop/cop/sidekiq_options_queue.rb +++ b/rubocop/cop/sidekiq_options_queue.rb @@ -4,7 +4,7 @@ module RuboCop module Cop # Cop that prevents manually setting a queue in Sidekiq workers. class SidekiqOptionsQueue < RuboCop::Cop::Cop - MSG = 'Do not manually set a queue; `ApplicationWorker` sets one automatically.'.freeze + MSG = 'Do not manually set a queue; `ApplicationWorker` sets one automatically.' def_node_matcher :sidekiq_options?, <<~PATTERN (send nil? :sidekiq_options $...) |