Commit Graph

7 Commits

Author SHA1 Message Date
Sean McGivern ab0a6455c7 Add RSpec/TopLevelDescribePath cop
The RSpec/FilePath cop checks that a spec file's path is correct, but
only if the file describes a constant. We want to check, for any file
with a top-level `describe`, whether the file path ends in
`_spec.rb`. We don't care what comes before that; just that it will be
executed by RSpec at all.
2019-08-01 11:07:26 +01:00
Rémy Coutable 4b035896c4
Introduce a new FactoriesInMigrationSpecs cop
Signed-off-by: Rémy Coutable <remy@rymai.me>
2018-04-06 17:41:52 +02:00
Rémy Coutable a2d39b8010 Use gitlab-styles
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-12-22 08:34:44 -06:00
Rémy Coutable 8a31b07437 Add a new RSpec::EnvAssignment cop to prevent assigning to ENV in specs
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-10-18 18:42:09 +02:00
Jacopo 0ce6785851 Replaces `tag: true` into `:tag` in the specs
Replaces all the explicit include metadata syntax in the specs (tag:
true) into the implicit one (:tag).
Added a cop to prevent future errors and handle autocorrection.
2017-10-07 13:57:54 +02:00
Robert Speicher c5a88df6b7 Require rubocop-rspec in the correct location
Resolves the `codeclimate` CI failure
2017-06-14 17:08:34 -05:00
Robert Speicher 69ad827e82 Add a custom RSpec/SingleLineHook cop
This cop adds an offense when `before`, `after`, or `around` are used as
single-line blocks.
2017-06-14 13:16:44 -05:00