rubocop-rspec 2.24.0 → 2.24.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +18 -14
- data/config/default.yml +1 -1
- data/config/obsoletion.yml +0 -6
- data/lib/rubocop/cop/rspec/file_path.rb +6 -0
- data/lib/rubocop/rspec/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c86b897dee5441bce313de34844ccae87313b9a5f8b4d84d3957b2a36d48aa5a
|
4
|
+
data.tar.gz: 517269204d37e39e80cb75b75d517e55817c8c13ec6a4574a8ed7d12d85145c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aed811c032c6094c898369be38925f59e7cd637de6268f0a5787d123b20505058b1659102bfc571a134983f51cf5984848caf7d7c539bf7816c94a6471f4ae19
|
7
|
+
data.tar.gz: cdd65ce7e146cc32035fef6d258fac99a6191b62e57e3e32b89176faa8d9ab6fc44400d37f903e4e71b64515292f8a2734aaa723099d0e5cf2064a29cbbb7032
|
data/CHANGELOG.md
CHANGED
@@ -2,9 +2,13 @@
|
|
2
2
|
|
3
3
|
## Master (Unreleased)
|
4
4
|
|
5
|
+
## 2.24.1 (2023-09-23)
|
6
|
+
|
7
|
+
- Fix an error when using `RSpec/FilePath` and revert to enabled by default. If you have already moved to `RSpec/SpecFilePathSuffix` and `RSpec/SpecFilePathFormat`, disable `RSpec/FilePath` explicitly as `Enabled: false`. The `RSpec/FilePath` before migration and the `RSpec/SpecFilePathSuffix` and `RSpec/SpecFilePathFormat` as the target are available respectively. ([@ydah])
|
8
|
+
|
5
9
|
## 2.24.0 (2023-09-08)
|
6
10
|
|
7
|
-
- Split `RSpec/FilePath` into `RSpec/SpecFilePathSuffix` and `RSpec/SpecFilePathFormat`. `RSpec/FilePath` cop is
|
11
|
+
- Split `RSpec/FilePath` into `RSpec/SpecFilePathSuffix` and `RSpec/SpecFilePathFormat`. `RSpec/FilePath` cop is disabled by default and the two new cops are pending and need to be enabled explicitly. ([@ydah])
|
8
12
|
- Add new `RSpec/Eq` cop. ([@ydah])
|
9
13
|
- Add `RSpec/MetadataStyle` and `RSpec/EmptyMetadata` cops. ([@r7kamura])
|
10
14
|
- Add support `RSpec/Rails/HttpStatus` when `have_http_status` with string argument. ([@ydah])
|
@@ -19,7 +23,7 @@
|
|
19
23
|
|
20
24
|
## 2.23.1 (2023-08-07)
|
21
25
|
|
22
|
-
- Mark to `Safe: false` for `RSpec/Rails/NegationBeValid`
|
26
|
+
- Mark to `Safe: false` for `RSpec/Rails/NegationBeValid` cop. ([@ydah])
|
23
27
|
- Declare autocorrect as unsafe for `RSpec/ReceiveMessages`. ([@bquorning])
|
24
28
|
|
25
29
|
## 2.23.0 (2023-07-30)
|
@@ -28,13 +32,13 @@
|
|
28
32
|
- Fix a false negative for `RSpec/ExcessiveDocstringSpacing` when finds description with em space. ([@ydah])
|
29
33
|
- Fix a false positive for `RSpec/EmptyExampleGroup` when example group with examples defined in `if` branch inside iterator. ([@ydah])
|
30
34
|
- Update the message output of `RSpec/ExpectActual` to include the word 'value'. ([@corydiamand])
|
31
|
-
- Fix a false negative for `RSpec/Pending` when
|
35
|
+
- Fix a false negative for `RSpec/Pending` when `it` without body. ([@ydah])
|
32
36
|
- Add new `RSpec/ReceiveMessages` cop. ([@ydah])
|
33
37
|
- Change default.yml path to use `**/spec/*` instead of `spec/*`. ([@ydah])
|
34
|
-
- Add `AllowedIdentifiers` and `AllowedPatterns` configuration option to `RSpec/IndexedLet`.
|
38
|
+
- Add `AllowedIdentifiers` and `AllowedPatterns` configuration option to `RSpec/IndexedLet`. ([@ydah])
|
35
39
|
- Fix `RSpec/NamedSubject` when block has no body. ([@splattael])
|
36
40
|
- Fix `RSpec/LetBeforeExamples` autocorrect incompatible with `RSpec/ScatteredLet` autocorrect. ([@ydah])
|
37
|
-
- Update `RSpec/Focus` to support `shared_context` and `shared_examples
|
41
|
+
- Update `RSpec/Focus` to support `shared_context` and `shared_examples`. ([@tmaier])
|
38
42
|
|
39
43
|
## 2.22.0 (2023-05-06)
|
40
44
|
|
@@ -56,9 +60,9 @@
|
|
56
60
|
- Add support `be_status` style for `RSpec/Rails/HttpStatus`. ([@ydah])
|
57
61
|
- Add support for shared example groups to `RSpec/EmptyLineAfterExampleGroup`. ([@pirj])
|
58
62
|
- Add support for `RSpec/HaveHttpStatus` when using `response.code`. ([@ydah])
|
59
|
-
- Fix order of expected and actual in correction for `RSpec/Rails/MinitestAssertions
|
63
|
+
- Fix order of expected and actual in correction for `RSpec/Rails/MinitestAssertions`. ([@mvz])
|
60
64
|
- Fix a false positive for `RSpec/DescribedClassModuleWrapping` when RSpec.describe numblock is nested within a module. ([@ydah])
|
61
|
-
- Fix a false positive for `RSpec/FactoryBot/ConsistentParenthesesStyle` inside `&&`, `||` and `:?` when `omit_parentheses` is on ([@dmitrytsepelev])
|
65
|
+
- Fix a false positive for `RSpec/FactoryBot/ConsistentParenthesesStyle` inside `&&`, `||` and `:?` when `omit_parentheses` is on. ([@dmitrytsepelev])
|
62
66
|
- Fix a false positive for `RSpec/PendingWithoutReason` when pending/skip has a reason inside an example group. ([@ydah])
|
63
67
|
- Fix a false negative for `RSpec/RedundantAround` when redundant numblock `around`. ([@ydah])
|
64
68
|
- Change `RSpec/ContainExactly` to ignore calls with no arguments, and change `RSpec/MatchArray` to ignore calls with an empty array literal argument. ([@ydah], [@bquorning])
|
@@ -111,7 +115,7 @@
|
|
111
115
|
- Improved processing speed for `RSpec/Be`, `RSpec/ExpectActual`, `RSpec/ImplicitExpect`, `RSpec/MessageSpies`, `RSpec/PredicateMatcher` and `RSpec/Rails/HaveHttpStatus`. ([@ydah])
|
112
116
|
- Fix wrong autocorrection in `n_times` style on `RSpec/FactoryBot/CreateList`. ([@r7kamura])
|
113
117
|
- Fix a false positive for `RSpec/FactoryBot/ConsistentParenthesesStyle` when using `generate` with multiple arguments. ([@ydah])
|
114
|
-
- Mark `RSpec/BeEq` as `Safe: false
|
118
|
+
- Mark `RSpec/BeEq` as `Safe: false`. ([@r7kamura])
|
115
119
|
- Add `RSpec/DuplicatedMetadata` cop. ([@r7kamura])
|
116
120
|
- Mark `RSpec/BeEql` as `Safe: false`. ([@r7kamura])
|
117
121
|
- Add `RSpec/PendingWithoutReason` cop. ([@r7kamura])
|
@@ -144,8 +148,8 @@
|
|
144
148
|
- Fix a false positive for `RSpec/Capybara/SpecificMatcher` when `have_css("a")` without attribute. ([@ydah])
|
145
149
|
- Update `RSpec/ExampleWording` cop to raise error for insufficient descriptions. ([@akrox58])
|
146
150
|
- Add new `RSpec/Capybara/NegationMatcher` cop. ([@ydah])
|
147
|
-
- Add `AllowedPatterns` configuration option to `RSpec/NoExpectationExample`.
|
148
|
-
- Improve `RSpec/NoExpectationExample` cop to ignore examples skipped or pending via metadata.
|
151
|
+
- Add `AllowedPatterns` configuration option to `RSpec/NoExpectationExample`. ([@ydah])
|
152
|
+
- Improve `RSpec/NoExpectationExample` cop to ignore examples skipped or pending via metadata. ([@pirj])
|
149
153
|
- Add `RSpec/FactoryBot/ConsistentParenthesesStyle` cop. ([@Liberatys])
|
150
154
|
- Add `RSpec/Rails/InferredSpecType` cop. ([@r7kamura])
|
151
155
|
- Add new `RSpec/Capybara/SpecificActions` cop. ([@ydah])
|
@@ -461,7 +465,7 @@
|
|
461
465
|
- Add config to `RSpec/VerifiedDoubles` to enforcement of verification on unnamed doubles. ([@BrentWheeldon])
|
462
466
|
- Fix `FactoryBot/AttributeDefinedStatically` not working when there is a non-symbol key. ([@vzvu3k6k])
|
463
467
|
- Fix false positive in `RSpec/ImplicitSubject` when `is_expected` is used inside `its()` block. ([@Darhazer])
|
464
|
-
- Add `single_statement_only` style to
|
468
|
+
- Add `single_statement_only` style to `RSpec/ImplicitSubject` as a more relaxed alternative to `single_line_only`. ([@Darhazer])
|
465
469
|
- Add `RSpec/UnspecifiedException` as a default cop to encourage more-specific `expect{}.to raise_error(ExceptionType)`, or `raise_exception` style handling of exceptions. ([@daveworth])
|
466
470
|
|
467
471
|
## 1.29.1 (2018-09-01)
|
@@ -496,14 +500,14 @@
|
|
496
500
|
|
497
501
|
## 1.26.0 (2018-06-06)
|
498
502
|
|
499
|
-
- Fix false positive in `RSpec/EmptyExampleGroup` cop when methods named like a RSpec method are used.
|
503
|
+
- Fix false positive in `RSpec/EmptyExampleGroup` cop when methods named like a RSpec method are used. ([@Darhazer])
|
500
504
|
- Fix `Capybara/FeatureMethods` not working when there is require before the spec. ([@Darhazer])
|
501
505
|
- Fix `RSpec/EmptyLineAfterFinalLet`: allow a comment to be placed after latest let, requiring empty line after the comment. ([@Darhazer])
|
502
506
|
- Add `RSpec/ReceiveCounts` cop to enforce usage of :once and :twice matchers. ([@Darhazer])
|
503
507
|
|
504
508
|
## 1.25.1 (2018-04-10)
|
505
509
|
|
506
|
-
- Fix false positive in `RSpec/Pending` cop when pending is used as a method name.
|
510
|
+
- Fix false positive in `RSpec/Pending` cop when pending is used as a method name. ([@Darhazer])
|
507
511
|
- Fix `FactoryBot/DynamicAttributeDefinedStatically` false positive when using symbol proc argument for a sequence. ([@tdeo])
|
508
512
|
|
509
513
|
## 1.25.0 (2018-04-07)
|
@@ -511,7 +515,7 @@
|
|
511
515
|
- Add `RSpec/SharedExamples` cop to enforce consistent usage of string to titleize shared examples. ([@anthony-robin])
|
512
516
|
- Add `RSpec/Be` cop to enforce passing argument to the generic `be` matcher. ([@Darhazer])
|
513
517
|
- Fix false positives in `StaticAttributeDefinedDynamically` and `ReturnFromStub` when a const is used in an array or hash. ([@Darhazer])
|
514
|
-
- Add `RSpec/Pending` cop to enforce no existing pending or skipped examples.
|
518
|
+
- Add `RSpec/Pending` cop to enforce no existing pending or skipped examples. This is disabled by default. ([@patrickomatic])
|
515
519
|
- Fix `RSpec/NestedGroups` cop support --auto-gen-config. ([@walf443])
|
516
520
|
- Fix false positives in `Capybara/FeatureMethods` when feature methods are used as property names in a factory. ([@Darhazer])
|
517
521
|
- Allow configuring enabled methods in `Capybara/FeatureMethods`. ([@Darhazer])
|
data/config/default.yml
CHANGED
data/config/obsoletion.yml
CHANGED
@@ -27,9 +27,3 @@ renamed:
|
|
27
27
|
RSpec/FactoryBot/FactoryClassName: FactoryBot/FactoryClassName
|
28
28
|
RSpec/FactoryBot/FactoryNameStyle: FactoryBot/FactoryNameStyle
|
29
29
|
RSpec/FactoryBot/SyntaxMethods: FactoryBot/SyntaxMethods
|
30
|
-
|
31
|
-
split:
|
32
|
-
RSpec/FilePath:
|
33
|
-
alternatives:
|
34
|
-
- RSpec/SpecFilePathFormat
|
35
|
-
- RSpec/SpecFilePathSuffix
|
@@ -5,6 +5,12 @@ module RuboCop
|
|
5
5
|
module RSpec
|
6
6
|
# Checks that spec file paths are consistent and well-formed.
|
7
7
|
#
|
8
|
+
# This cop is deprecated.
|
9
|
+
# We plan to remove it in the next major version update to 3.0.
|
10
|
+
# The migration targets are `RSpec/SpecFilePathSuffix`
|
11
|
+
# and `RSpec/SpecFilePathFormat`.
|
12
|
+
# If you are using this cop, please plan for migration.
|
13
|
+
#
|
8
14
|
# By default, this checks that spec file paths are consistent with the
|
9
15
|
# test subject and enforces that it reflects the described
|
10
16
|
# class/module and its optionally called out method.
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubocop-rspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.24.
|
4
|
+
version: 2.24.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Backus
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2023-09-
|
13
|
+
date: 2023-09-23 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rubocop
|