From: Tom Hughes Date: Tue, 23 Jan 2024 18:14:28 +0000 (+0000) Subject: Fix new rubocop warnings X-Git-Tag: live~764 X-Git-Url: https://git.openstreetmap.org./rails.git/commitdiff_plain/e71355c5bbb581e1d18f9ed59861f1eaeee5955a Fix new rubocop warnings --- diff --git a/.rubocop.yml b/.rubocop.yml index ddfb63cae..1e18afd83 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -68,9 +68,6 @@ Rails/SkipsModelValidations: - 'db/migrate/*.rb' - 'app/controllers/users_controller.rb' -Style/ArgumentsForwarding: - Enabled: false - Style/Documentation: Enabled: false diff --git a/test/helpers/asset_helper_test.rb b/test/helpers/asset_helper_test.rb index 8a4653b25..c255cc766 100644 --- a/test/helpers/asset_helper_test.rb +++ b/test/helpers/asset_helper_test.rb @@ -2,6 +2,6 @@ require "test_helper" class AssetHelperTest < ActionView::TestCase def test_assets - assert assets("iD").is_a?(Hash) + assert_kind_of Hash, assets("iD") end end diff --git a/test/lib/i18n_test.rb b/test/lib/i18n_test.rb index ea6e4ae27..fe94cbdd3 100644 --- a/test/lib/i18n_test.rb +++ b/test/lib/i18n_test.rb @@ -42,7 +42,7 @@ class I18nTest < ActiveSupport::TestCase assert_includes value, :other, "#{key}.other plural key missing" else - assert value.is_a?(String), "#{key} is not a string" + assert_kind_of String, value, "#{key} is not a string" value.scan(/%\{(\w+)\}/) do assert_includes variables, Regexp.last_match(1), "#{key} uses unknown interpolation variable #{Regexp.last_match(1)}"