1 # This configuration was generated by
2 # `rubocop --auto-gen-config`
3 # on 2024-08-27 18:01:13 UTC using RuboCop version 1.65.1.
4 # The point is for the user to remove these configuration records
5 # one by one as the offenses are removed from the code base.
6 # Note that changes in the inspected code, or installation of new
7 # versions of RuboCop, may require this file to be generated again.
9 # Work around erblint issues.
10 # https://github.com/openstreetmap/openstreetmap-website/issues/2472
18 # Configuration parameters: Include, MaxAmount.
19 # Include: **/*_spec.rb, **/spec/**/*, **/test/**/*, **/features/support/factories/**/*.rb
20 FactoryBot/ExcessiveCreateList:
22 - 'test/controllers/api/changeset_comments_controller_test.rb'
23 - 'test/controllers/api/messages/inboxes_controller_test.rb'
24 - 'test/controllers/api/messages/outboxes_controller_test.rb'
25 - 'test/controllers/changesets_controller_test.rb'
26 - 'test/controllers/diary_entries_controller_test.rb'
27 - 'test/controllers/notes_controller_test.rb'
28 - 'test/controllers/traces_controller_test.rb'
29 - 'test/controllers/user_blocks_controller_test.rb'
30 - 'test/controllers/users/issued_blocks_controller_test.rb'
31 - 'test/controllers/users/received_blocks_controller_test.rb'
32 - 'test/system/users_test.rb'
35 # This cop supports safe autocorrection (--autocorrect).
36 # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns.
37 # URISchemes: http, https
42 # This cop supports unsafe autocorrection (--autocorrect-all).
43 # Configuration parameters: AllowSafeAssignment.
44 Lint/AssignmentInCondition:
46 - 'app/controllers/accounts_controller.rb'
47 - 'app/controllers/api/traces_controller.rb'
48 - 'app/controllers/api/user_preferences_controller.rb'
49 - 'app/controllers/geocoder_controller.rb'
50 - 'app/controllers/traces_controller.rb'
51 - 'app/controllers/users_controller.rb'
52 - 'app/helpers/application_helper.rb'
53 - 'app/helpers/browse_tags_helper.rb'
54 - 'app/mailers/user_mailer.rb'
55 - 'app/models/client_application.rb'
58 - 'script/deliver-message'
61 # Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
66 # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
67 # AllowedMethods: refine
72 # Configuration parameters: CountBlocks, CountModifierForms.
77 # Configuration parameters: CountComments, CountAsOne.
82 # Configuration parameters: AllowedMethods, AllowedPatterns.
83 Metrics/CyclomaticComplexity:
87 # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
92 # Configuration parameters: CountKeywordArgs, MaxOptionalParameters.
93 Metrics/ParameterLists:
97 # Configuration parameters: AllowedMethods, AllowedPatterns.
98 Metrics/PerceivedComplexity:
101 # Offense count: 2784
102 # This cop supports safe autocorrection (--autocorrect).
103 Minitest/EmptyLineBeforeAssertionMethods:
107 Minitest/MultipleAssertions:
111 # This cop supports unsafe autocorrection (--autocorrect-all).
112 Rails/ActionControllerFlashBeforeRender:
114 - 'app/controllers/application_controller.rb'
115 - 'app/controllers/confirmations_controller.rb'
116 - 'app/controllers/friendships_controller.rb'
117 - 'app/controllers/issue_comments_controller.rb'
118 - 'app/controllers/messages_controller.rb'
119 - 'app/controllers/passwords_controller.rb'
120 - 'app/controllers/traces_controller.rb'
121 - 'app/controllers/user_blocks_controller.rb'
122 - 'app/controllers/users_controller.rb'
125 # Configuration parameters: Include.
126 # Include: app/models/**/*.rb
127 Rails/HasAndBelongsToMany:
129 - 'app/models/changeset.rb'
130 - 'app/models/user.rb'
133 # Configuration parameters: Include.
134 # Include: app/helpers/**/*.rb
135 Rails/HelperInstanceVariable:
137 - 'app/helpers/title_helper.rb'
140 # Configuration parameters: IgnoreScopes, Include.
141 # Include: app/models/**/*.rb
144 - 'app/models/changeset.rb'
145 - 'app/models/diary_entry.rb'
146 - 'app/models/friendship.rb'
147 - 'app/models/issue.rb'
148 - 'app/models/message.rb'
149 - 'app/models/note.rb'
150 - 'app/models/user.rb'
153 # Configuration parameters: Include.
154 # Include: app/controllers/**/*.rb, app/mailers/**/*.rb
155 Rails/LexicallyScopedActionFilter:
157 - 'app/controllers/oauth2_applications_controller.rb'
160 # Configuration parameters: Database, Include.
161 # SupportedDatabases: mysql
162 # Include: db/**/*.rb
165 - 'db/migrate/002_cleanup_osm_db.rb'
166 - 'db/migrate/020_populate_node_tags_and_remove.rb'
167 - 'db/migrate/021_move_to_innodb.rb'
168 - 'db/migrate/025_add_end_time_to_changesets.rb'
169 - 'db/migrate/20120404205604_add_user_and_description_to_redaction.rb'
174 - 'app/helpers/application_helper.rb'
175 - 'app/helpers/user_mailer_helper.rb'
177 - 'test/helpers/application_helper_test.rb'
180 # Configuration parameters: Include.
181 # Include: db/**/*.rb
182 Rails/ThreeStateBooleanColumn:
184 - 'db/migrate/001_create_osm_db.rb'
185 - 'db/migrate/006_tile_nodes.rb'
186 - 'db/migrate/007_add_relations.rb'
187 - 'db/migrate/054_refactor_map_bug_tables.rb'
188 - 'db/migrate/20140507110937_create_changeset_comments.rb'
191 # This cop supports safe autocorrection (--autocorrect).
194 - 'lib/tasks/auto_annotate_models.rake'
195 - 'lib/tasks/eslint.rake'
196 - 'lib/tasks/subscribe_diary_authors.rake'
197 - 'lib/tasks/subscribe_old_changesets.rake'
200 # This cop supports unsafe autocorrection (--autocorrect-all).
201 # Configuration parameters: EnforcedStyle.
202 # SupportedStyles: always, always_true, never
203 Style/FrozenStringLiteralComment:
207 # This cop supports safe autocorrection (--autocorrect).
208 # Configuration parameters: Strict, AllowedNumbers, AllowedPatterns.
209 Style/NumericLiterals: