rubocop-minitest 0.12.0 → 0.12.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/lib/rubocop/cop/mixin/minitest_exploration_helpers.rb +1 -8
- data/lib/rubocop/minitest/version.rb +1 -1
- data/relnotes/v0.12.1.md +5 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3e7a3871e612b7ff9a9fd9c5c83bb092ea6097f6b4838246b45346dd4ccc0d4a
|
4
|
+
data.tar.gz: 1ba5c7ebe8764918e623fc45a5dc198700172ea5892db6744cbfd01eaf449023
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9ddaa753e8ed446249b730b252e6c7d5e7b2b8029e65c025cd5a7b451fd53f9b0205e8bded8e7aa3be8ec476322c600d04b7b88c300543d8266526ab92a491e0
|
7
|
+
data.tar.gz: 404825f75cd7d39bb6945dcda51f17c012529874feb662b4f4eeb821c63b4931f49ff64391b7deac1111361bd4fd4e458740f1e2c20047d8898d9ae3192c6341
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,12 @@
|
|
2
2
|
|
3
3
|
## master (unreleased)
|
4
4
|
|
5
|
+
## 0.12.1 (2021-04-25)
|
6
|
+
|
7
|
+
### Bug fixes
|
8
|
+
|
9
|
+
* [#131](https://github.com/rubocop/rubocop-minitest/issues/131): Fix an error for `Minitest/MultipleAssertions` and fixes a false positive for `test` block. ([@koic][])
|
10
|
+
|
5
11
|
## 0.12.0 (2021-04-23)
|
6
12
|
|
7
13
|
### New features
|
@@ -44,8 +44,7 @@ module RuboCop
|
|
44
44
|
end
|
45
45
|
|
46
46
|
def test_cases(class_node)
|
47
|
-
|
48
|
-
test_method_calls(class_node)
|
47
|
+
class_def_nodes(class_node).select { |def_node| test_case_name?(def_node.method_name) }
|
49
48
|
end
|
50
49
|
|
51
50
|
def lifecycle_hooks(class_node)
|
@@ -64,12 +63,6 @@ module RuboCop
|
|
64
63
|
end
|
65
64
|
end
|
66
65
|
|
67
|
-
# support https://api.rubyonrails.org/classes/ActiveSupport/Testing/Declarative.html
|
68
|
-
def test_method_calls(class_node)
|
69
|
-
block_nodes = class_node.each_descendant(:block)
|
70
|
-
block_nodes.select { |block_node| block_node.method?(:test) }
|
71
|
-
end
|
72
|
-
|
73
66
|
def test_case_name?(name)
|
74
67
|
name.to_s.start_with?('test_')
|
75
68
|
end
|
data/relnotes/v0.12.1.md
ADDED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubocop-minitest
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.12.
|
4
|
+
version: 0.12.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bozhidar Batsov
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: exe
|
12
12
|
cert_chain: []
|
13
|
-
date: 2021-04-
|
13
|
+
date: 2021-04-25 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rubocop
|
@@ -137,6 +137,7 @@ files:
|
|
137
137
|
- relnotes/v0.11.0.md
|
138
138
|
- relnotes/v0.11.1.md
|
139
139
|
- relnotes/v0.12.0.md
|
140
|
+
- relnotes/v0.12.1.md
|
140
141
|
- relnotes/v0.2.0.md
|
141
142
|
- relnotes/v0.2.1.md
|
142
143
|
- relnotes/v0.3.0.md
|