rubocop-minitest 0.20.1 → 0.22.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/config/default.yml +11 -0
- data/lib/rubocop/cop/generator.rb +1 -7
- data/lib/rubocop/cop/minitest/assert_in_delta.rb +1 -1
- data/lib/rubocop/cop/minitest/assert_match.rb +1 -1
- data/lib/rubocop/cop/minitest/assert_predicate.rb +1 -1
- data/lib/rubocop/cop/minitest/assert_raises_compound_body.rb +45 -0
- data/lib/rubocop/cop/minitest/assert_raises_with_regexp_argument.rb +36 -0
- data/lib/rubocop/cop/minitest/assert_silent.rb +1 -1
- data/lib/rubocop/cop/minitest/refute_equal.rb +1 -2
- data/lib/rubocop/cop/minitest/refute_in_delta.rb +1 -1
- data/lib/rubocop/cop/minitest/refute_predicate.rb +1 -1
- data/lib/rubocop/cop/minitest/unreachable_assertion.rb +1 -1
- data/lib/rubocop/cop/minitest_cops.rb +2 -0
- data/lib/rubocop/cop/mixin/argument_range_helper.rb +4 -12
- data/lib/rubocop/cop/mixin/in_delta_mixin.rb +1 -0
- data/lib/rubocop/cop/mixin/minitest_cop_rule.rb +11 -4
- data/lib/rubocop/cop/mixin/minitest_exploration_helpers.rb +1 -0
- data/lib/rubocop/cop/mixin/nil_assertion_handleable.rb +1 -0
- data/lib/rubocop/cop/mixin/predicate_assertion_handleable.rb +2 -5
- data/lib/rubocop/minitest/assert_offense.rb +1 -1
- data/lib/rubocop/minitest/version.rb +1 -1
- metadata +5 -79
- data/.circleci/config.yml +0 -55
- data/.gitattributes +0 -1
- data/.github/FUNDING.yml +0 -7
- data/.github/ISSUE_TEMPLATE/bug_report.md +0 -43
- data/.github/ISSUE_TEMPLATE/feature_request.md +0 -20
- data/.github/PULL_REQUEST_TEMPLATE.md +0 -17
- data/.github/workflows/linting.yml +0 -15
- data/.github/workflows/spell_checking.yml +0 -33
- data/.gitignore +0 -61
- data/.rubocop.yml +0 -101
- data/.rubocop_todo.yml +0 -19
- data/.yamllint.yml +0 -9
- data/.yardopts +0 -3
- data/CHANGELOG.md +0 -323
- data/CONTRIBUTING.md +0 -69
- data/Gemfile +0 -16
- data/Rakefile +0 -60
- data/bin/console +0 -11
- data/bin/setup +0 -8
- data/codespell.txt +0 -0
- data/docs/antora.yml +0 -7
- data/docs/modules/ROOT/nav.adoc +0 -6
- data/docs/modules/ROOT/pages/cops.adoc +0 -55
- data/docs/modules/ROOT/pages/cops_minitest.adoc +0 -1412
- data/docs/modules/ROOT/pages/index.adoc +0 -5
- data/docs/modules/ROOT/pages/installation.adoc +0 -15
- data/docs/modules/ROOT/pages/usage.adoc +0 -32
- data/legacy-docs/cops.md +0 -23
- data/legacy-docs/cops_minitest.md +0 -448
- data/legacy-docs/index.md +0 -1
- data/legacy-docs/installation.md +0 -11
- data/legacy-docs/usage.md +0 -27
- data/mkdocs.yml +0 -13
- data/readthedocs.yml +0 -5
- data/relnotes/v0.1.0.md +0 -7
- data/relnotes/v0.10.0.md +0 -21
- data/relnotes/v0.10.1.md +0 -5
- data/relnotes/v0.10.2.md +0 -5
- data/relnotes/v0.10.3.md +0 -5
- data/relnotes/v0.11.0.md +0 -16
- data/relnotes/v0.11.1.md +0 -5
- data/relnotes/v0.12.0.md +0 -10
- data/relnotes/v0.12.1.md +0 -5
- data/relnotes/v0.13.0.md +0 -5
- data/relnotes/v0.14.0.md +0 -5
- data/relnotes/v0.15.0.md +0 -5
- data/relnotes/v0.15.1.md +0 -5
- data/relnotes/v0.15.2.md +0 -5
- data/relnotes/v0.16.0.md +0 -11
- data/relnotes/v0.17.0.md +0 -5
- data/relnotes/v0.17.1.md +0 -5
- data/relnotes/v0.17.2.md +0 -5
- data/relnotes/v0.18.0.md +0 -9
- data/relnotes/v0.19.0.md +0 -5
- data/relnotes/v0.19.1.md +0 -5
- data/relnotes/v0.2.0.md +0 -9
- data/relnotes/v0.2.1.md +0 -5
- data/relnotes/v0.20.0.md +0 -13
- data/relnotes/v0.20.1.md +0 -5
- data/relnotes/v0.3.0.md +0 -16
- data/relnotes/v0.4.0.md +0 -14
- data/relnotes/v0.4.1.md +0 -5
- data/relnotes/v0.5.0.md +0 -5
- data/relnotes/v0.5.1.md +0 -5
- data/relnotes/v0.6.0.md +0 -5
- data/relnotes/v0.6.1.md +0 -6
- data/relnotes/v0.6.2.md +0 -5
- data/relnotes/v0.7.0.md +0 -13
- data/relnotes/v0.8.0.md +0 -12
- data/relnotes/v0.8.1.md +0 -5
- data/relnotes/v0.9.0.md +0 -10
- data/rubocop-minitest.gemspec +0 -40
- data/tasks/changelog.rake +0 -34
- data/tasks/changelog.rb +0 -166
- data/tasks/cops_documentation.rake +0 -50
- data/tasks/cut_release.rake +0 -91
@@ -1,33 +0,0 @@
|
|
1
|
-
name: Spell Checking
|
2
|
-
|
3
|
-
on: [pull_request]
|
4
|
-
|
5
|
-
jobs:
|
6
|
-
codespell:
|
7
|
-
name: Check spelling of all files with codespell
|
8
|
-
runs-on: ubuntu-latest
|
9
|
-
strategy:
|
10
|
-
matrix:
|
11
|
-
python-version: [3.8]
|
12
|
-
steps:
|
13
|
-
- uses: actions/checkout@v3
|
14
|
-
- name: Set up Python ${{ matrix.python-version }}
|
15
|
-
uses: actions/setup-python@v2
|
16
|
-
with:
|
17
|
-
python-version: ${{ matrix.python-version }}
|
18
|
-
- name: Install dependencies
|
19
|
-
run: |
|
20
|
-
python -m pip install --upgrade pip
|
21
|
-
pip install codespell
|
22
|
-
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
|
23
|
-
- name: Check spelling with codespell
|
24
|
-
run: codespell --ignore-words=codespell.txt || exit 1
|
25
|
-
misspell:
|
26
|
-
name: Check spelling of all files in commit with misspell
|
27
|
-
runs-on: ubuntu-latest
|
28
|
-
steps:
|
29
|
-
- uses: actions/checkout@v3
|
30
|
-
- name: Install
|
31
|
-
run: wget -O - -q https://raw.githubusercontent.com/client9/misspell/master/install-misspell.sh | sh -s -- -b .
|
32
|
-
- name: Misspell
|
33
|
-
run: git ls-files --empty-directory | xargs ./misspell -error
|
data/.gitignore
DELETED
@@ -1,61 +0,0 @@
|
|
1
|
-
# rcov generated
|
2
|
-
coverage
|
3
|
-
coverage.data
|
4
|
-
|
5
|
-
# rdoc generated
|
6
|
-
rdoc
|
7
|
-
|
8
|
-
# yard generated
|
9
|
-
doc
|
10
|
-
.yardoc
|
11
|
-
|
12
|
-
# bundler
|
13
|
-
.bundle
|
14
|
-
Gemfile.lock
|
15
|
-
Gemfile.local
|
16
|
-
|
17
|
-
# rbenv
|
18
|
-
.ruby-version
|
19
|
-
|
20
|
-
# rspec
|
21
|
-
/spec/examples.txt
|
22
|
-
/.test_queue_stats
|
23
|
-
|
24
|
-
# jeweler generated
|
25
|
-
pkg
|
26
|
-
|
27
|
-
# etags
|
28
|
-
TAGS
|
29
|
-
|
30
|
-
# Have editor/IDE/OS specific files you need to ignore? Consider using a global gitignore:
|
31
|
-
#
|
32
|
-
# * Create a file at ~/.gitignore
|
33
|
-
# * Include files you want ignored
|
34
|
-
# * Run: git config --global core.excludesfile ~/.gitignore
|
35
|
-
#
|
36
|
-
# After doing this, these files will be ignored in all your git projects,
|
37
|
-
# saving you from having to 'pollute' every project you touch with them
|
38
|
-
#
|
39
|
-
# Not sure what to needs to be ignored for particular editors/OSes? Here's some ideas to get you started. (Remember, remove the leading # of the line)
|
40
|
-
#
|
41
|
-
# For MacOS:
|
42
|
-
#
|
43
|
-
#.DS_Store
|
44
|
-
|
45
|
-
# For TextMate
|
46
|
-
#*.tmproj
|
47
|
-
#tmtags
|
48
|
-
|
49
|
-
# For emacs:
|
50
|
-
#*~
|
51
|
-
#\#*
|
52
|
-
#.\#*
|
53
|
-
|
54
|
-
# For vim:
|
55
|
-
*.swp
|
56
|
-
|
57
|
-
# For redcar:
|
58
|
-
#.redcar
|
59
|
-
|
60
|
-
# For rubinius:
|
61
|
-
#*.rbc
|
data/.rubocop.yml
DELETED
@@ -1,101 +0,0 @@
|
|
1
|
-
inherit_from: .rubocop_todo.yml
|
2
|
-
|
3
|
-
# This is the configuration used to check the rubocop source code.
|
4
|
-
|
5
|
-
require:
|
6
|
-
- rubocop/cop/internal_affairs
|
7
|
-
- rubocop-performance
|
8
|
-
- rubocop-minitest
|
9
|
-
|
10
|
-
AllCops:
|
11
|
-
NewCops: enable
|
12
|
-
TargetRubyVersion: 2.6
|
13
|
-
SuggestExtensions: false
|
14
|
-
|
15
|
-
InternalAffairs/NodeMatcherDirective:
|
16
|
-
Enabled: false
|
17
|
-
|
18
|
-
# FIXME: Workaround for a false positive caused by this cop when using `bundle exec rake`.
|
19
|
-
InternalAffairs/UndefinedConfig:
|
20
|
-
Enabled: false
|
21
|
-
|
22
|
-
Naming/PredicateName:
|
23
|
-
# Method define macros for dynamically generated method.
|
24
|
-
MethodDefinitionMacros:
|
25
|
-
- define_method
|
26
|
-
- define_singleton_method
|
27
|
-
- def_node_matcher
|
28
|
-
- def_node_search
|
29
|
-
|
30
|
-
Naming/InclusiveLanguage:
|
31
|
-
Enabled: true
|
32
|
-
CheckStrings: true
|
33
|
-
FlaggedTerms:
|
34
|
-
behaviour:
|
35
|
-
Suggestions:
|
36
|
-
- behavior
|
37
|
-
offence:
|
38
|
-
Suggestions:
|
39
|
-
- offense
|
40
|
-
|
41
|
-
Style/FormatStringToken:
|
42
|
-
# Because we parse a lot of source codes from strings. Percent arrays
|
43
|
-
# look like unannotated format string tokens to this cop.
|
44
|
-
Exclude:
|
45
|
-
- test/**/*
|
46
|
-
|
47
|
-
Metrics/ClassLength:
|
48
|
-
Exclude:
|
49
|
-
- test/**/*
|
50
|
-
- tasks/changelog.rb
|
51
|
-
|
52
|
-
Layout/EndOfLine:
|
53
|
-
EnforcedStyle: lf
|
54
|
-
|
55
|
-
Layout/ClassStructure:
|
56
|
-
Enabled: true
|
57
|
-
Categories:
|
58
|
-
module_inclusion:
|
59
|
-
- include
|
60
|
-
- prepend
|
61
|
-
- extend
|
62
|
-
ExpectedOrder:
|
63
|
-
- module_inclusion
|
64
|
-
- constants
|
65
|
-
- public_class_methods
|
66
|
-
- initializer
|
67
|
-
- instance_methods
|
68
|
-
- protected_methods
|
69
|
-
- private_methods
|
70
|
-
|
71
|
-
# Trailing white space is meaningful in code examples
|
72
|
-
Layout/TrailingWhitespace:
|
73
|
-
AllowInHeredoc: true
|
74
|
-
|
75
|
-
Lint/AmbiguousBlockAssociation:
|
76
|
-
Exclude:
|
77
|
-
- 'test/**/*.rb'
|
78
|
-
|
79
|
-
Lint/InterpolationCheck:
|
80
|
-
Exclude:
|
81
|
-
- 'test/**/*.rb'
|
82
|
-
|
83
|
-
Lint/UselessAccessModifier:
|
84
|
-
MethodCreatingMethods:
|
85
|
-
- 'def_matcher'
|
86
|
-
- 'def_node_matcher'
|
87
|
-
|
88
|
-
Metrics/BlockLength:
|
89
|
-
Exclude:
|
90
|
-
- 'Rakefile'
|
91
|
-
- '**/*.rake'
|
92
|
-
- 'test/**/*.rb'
|
93
|
-
- 'rubocop-minitest.gemspec'
|
94
|
-
|
95
|
-
Naming/FileName:
|
96
|
-
Exclude:
|
97
|
-
- lib/rubocop-minitest.rb
|
98
|
-
|
99
|
-
Metrics/ModuleLength:
|
100
|
-
Exclude:
|
101
|
-
- 'test/**/*.rb'
|
data/.rubocop_todo.yml
DELETED
@@ -1,19 +0,0 @@
|
|
1
|
-
# This configuration was generated by
|
2
|
-
# `rubocop --auto-gen-config`
|
3
|
-
# on 2020-10-29 02:01:16 UTC using RuboCop version 1.0.0.
|
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.
|
8
|
-
|
9
|
-
# Offense count: 22
|
10
|
-
# Configuration parameters: CountComments, CountAsOne, ExcludedMethods.
|
11
|
-
Metrics/MethodLength:
|
12
|
-
Max: 14
|
13
|
-
Exclude:
|
14
|
-
- 'test/rubocop/cop/minitest/global_expectations_test.rb'
|
15
|
-
|
16
|
-
# Offense count: 1
|
17
|
-
Style/DocumentDynamicEvalDefinition:
|
18
|
-
Exclude:
|
19
|
-
- 'lib/rubocop/cop/mixin/minitest_cop_rule.rb'
|
data/.yamllint.yml
DELETED
data/.yardopts
DELETED
data/CHANGELOG.md
DELETED
@@ -1,323 +0,0 @@
|
|
1
|
-
# Change log
|
2
|
-
|
3
|
-
## master (unreleased)
|
4
|
-
|
5
|
-
## 0.20.1 (2022-06-13)
|
6
|
-
|
7
|
-
### Bug fixes
|
8
|
-
|
9
|
-
* [#175](https://github.com/rubocop/rubocop-minitest/pull/175): Fix raise error when using assert with block. ([@ippachi][])
|
10
|
-
|
11
|
-
## 0.20.0 (2022-05-29)
|
12
|
-
|
13
|
-
### New features
|
14
|
-
|
15
|
-
* [#169](https://github.com/rubocop/rubocop-minitest/issues/169): Add new `Minitest/SkipEnsure` cop. ([@koic][])
|
16
|
-
|
17
|
-
### Bug fixes
|
18
|
-
|
19
|
-
* [#172](https://github.com/rubocop/rubocop-minitest/issues/172): Fix a false positive for `Minitest/AssertPredicate` and `Minitest/RefutePredicate` when using numbered parameters. ([@koic][])
|
20
|
-
|
21
|
-
### Changes
|
22
|
-
|
23
|
-
* [#168](https://github.com/rubocop/rubocop-minitest/pull/168): **(Compatibility)** Drop Ruby 2.5 support. ([@koic][])
|
24
|
-
|
25
|
-
## 0.19.1 (2022-04-10)
|
26
|
-
|
27
|
-
### Bug fixes
|
28
|
-
|
29
|
-
* [#167](https://github.com/rubocop/rubocop-minitest/pull/167): Fix potential for valid Ruby code to be unparsable in `Minitest/DuplicateTestRun` cop. ([@gjtorikian][])
|
30
|
-
|
31
|
-
## 0.19.0 (2022-04-05)
|
32
|
-
|
33
|
-
### New features
|
34
|
-
|
35
|
-
* [#164](https://github.com/rubocop/rubocop-minitest/pull/164): Add new `Minitest/DuplicateTestRun` cop. ([@ignacio-chiazzo][])
|
36
|
-
|
37
|
-
## 0.18.0 (2022-03-13)
|
38
|
-
|
39
|
-
### New features
|
40
|
-
|
41
|
-
* [#161](https://github.com/rubocop/rubocop-minitest/pull/161): Add new `Minitest/AssertPredicate` and `Minitest/RefutePredicate` cops. ([@koic][])
|
42
|
-
|
43
|
-
### Changes
|
44
|
-
|
45
|
-
* [#162](https://github.com/rubocop/rubocop-minitest/pull/162): Make `Minitest/AssertNil` (`Minitest/RefuteNil`) aware of `assert_predicate(obj, :nil?)` (`refute_predicate(obj, :nil?)`). ([@koic][])
|
46
|
-
|
47
|
-
## 0.17.2 (2022-02-12)
|
48
|
-
|
49
|
-
### Bug fixes
|
50
|
-
|
51
|
-
* [#159](https://github.com/rubocop/rubocop-minitest/issues/159): Fix a false positive for `Minitest/UnreachableAssertion` when using only one assertion method in `assert_raises` block. ([@koic][])
|
52
|
-
|
53
|
-
## 0.17.1 (2022-01-30)
|
54
|
-
|
55
|
-
### Changes
|
56
|
-
|
57
|
-
* [#158](https://github.com/rubocop/rubocop-minitest/pull/158): Make `Minitest/UnreachableAssertion` aware of `assert` and `refute` prefix methods. ([@koic][])
|
58
|
-
|
59
|
-
## 0.17.0 (2021-11-23)
|
60
|
-
|
61
|
-
### New features
|
62
|
-
|
63
|
-
* [#155](https://github.com/rubocop/rubocop-minitest/issues/155): Provide `assert_offense`, `assert_correction`, and `assert_no_offenses` testing APIs for custom Minitest cop development. ([@koic][])
|
64
|
-
|
65
|
-
## 0.16.0 (2021-11-14)
|
66
|
-
|
67
|
-
### New features
|
68
|
-
|
69
|
-
* [#147](https://github.com/rubocop/rubocop-minitest/issues/147): Add `EnforcedStyle` config parameter for `Minitest/GlobalExpectations`. ([@gi][])
|
70
|
-
|
71
|
-
### Bug fixes
|
72
|
-
|
73
|
-
* [#142](https://github.com/rubocop/rubocop-minitest/issues/142): Fix `Minitest/GlobalExpectations` autocorrect when receiver is lambda. ([@gi][])
|
74
|
-
* [#150](https://github.com/rubocop/rubocop-minitest/issues/150): Fix a false positive for `Minitest/AssertEmpty` and `RefuteEmpty` cops when using `empty` method with any arguments. ([@koic][])
|
75
|
-
|
76
|
-
## 0.15.2 (2021-10-11)
|
77
|
-
|
78
|
-
### Bug fixes
|
79
|
-
|
80
|
-
* [#145](https://github.com/rubocop/rubocop-minitest/pull/145): Mark `Minitest/AssertEmptyLiteral` as safe autocorrection. ([@koic][])
|
81
|
-
|
82
|
-
## 0.15.1 (2021-09-26)
|
83
|
-
|
84
|
-
### Bug fixes
|
85
|
-
|
86
|
-
* [#143](https://github.com/rubocop/rubocop-minitest/issues/143): Fix an error for `Minitest/LiteralAsActualArgumentTest` when expected and actual arguments are literals. ([@koic][])
|
87
|
-
|
88
|
-
## 0.15.0 (2021-08-09)
|
89
|
-
|
90
|
-
### New features
|
91
|
-
|
92
|
-
* [#140](https://github.com/rubocop/rubocop-minitest/issues/140): Make `Minitest/AssertNil` and `Minitest/RefuteNil` aware of `assert(obj.nil?)` and `refute(obj.nil?)`. ([@koic][])
|
93
|
-
|
94
|
-
## 0.14.0 (2021-07-03)
|
95
|
-
|
96
|
-
### New features
|
97
|
-
|
98
|
-
* [#133](https://github.com/rubocop/rubocop-minitest/issues/133): Add new `Minitest/UnreachableAssertion` cop. ([@koic][])
|
99
|
-
|
100
|
-
## 0.13.0 (2021-06-20)
|
101
|
-
|
102
|
-
### New features
|
103
|
-
|
104
|
-
* [#136](https://github.com/rubocop/rubocop-minitest/pull/136): Support Active Support's `test` method for `Minitest/MultipleAssertions` and `Minitest/NoAssertions` cops. ([@koic][])
|
105
|
-
|
106
|
-
## 0.12.1 (2021-04-25)
|
107
|
-
|
108
|
-
### Bug fixes
|
109
|
-
|
110
|
-
* [#131](https://github.com/rubocop/rubocop-minitest/issues/131): Fix an error for `Minitest/MultipleAssertions` and fixes a false positive for `test` block. ([@koic][])
|
111
|
-
|
112
|
-
## 0.12.0 (2021-04-23)
|
113
|
-
|
114
|
-
### New features
|
115
|
-
|
116
|
-
* [#124](https://github.com/rubocop/rubocop-minitest/pull/124): Add new `Minitest/NoAssertions` cop. ([@ghiculescu][])
|
117
|
-
|
118
|
-
### Changes
|
119
|
-
|
120
|
-
* [#129](https://github.com/rubocop/rubocop-minitest/pull/129): **(Compatibility)** Drop Ruby 2.4 support. ([@koic][])
|
121
|
-
|
122
|
-
## 0.11.1 (2021-03-31)
|
123
|
-
|
124
|
-
### Changes
|
125
|
-
|
126
|
-
* [#126](https://github.com/rubocop/rubocop-minitest/issues/126): Mark `Minitest/AssertWithExpectedArgument` as unsafe. ([@koic][])
|
127
|
-
|
128
|
-
## 0.11.0 (2021-03-22)
|
129
|
-
|
130
|
-
### New features
|
131
|
-
|
132
|
-
* [#117](https://github.com/rubocop/rubocop-minitest/issues/117): Add new cop `Minitest/AssertWithExpectedArgument` to check for unintended usages of `assert` instead of `assert_equal`. ([@cstyles][])
|
133
|
-
|
134
|
-
### Bug fixes
|
135
|
-
|
136
|
-
* [#122](https://github.com/rubocop/rubocop-minitest/pull/122): Fix `Minitest/TestMethodName` for tests with multiple assertions. ([@ghiculescu][])
|
137
|
-
|
138
|
-
### Changes
|
139
|
-
|
140
|
-
* [#118](https://github.com/rubocop/rubocop-minitest/pull/118): **(BREAKING)** Fix `Minitest/AssertEmptyLiteral` by making it check for `assert_equal([], array)` instead of `assert([], array)`. ([@cstyles][])
|
141
|
-
* [#125](https://github.com/rubocop/rubocop-minitest/pull/125): Require RuboCop 0.90 or higher. ([@koic][])
|
142
|
-
|
143
|
-
## 0.10.3 (2021-01-12)
|
144
|
-
|
145
|
-
### Bug fixes
|
146
|
-
|
147
|
-
* [#115](https://github.com/rubocop/rubocop-minitest/issues/115): Fix a false positive for `Minitest/TestMethodName` for when defining test method has an argument, and test method without assertion methods. ([@koic][])
|
148
|
-
|
149
|
-
## 0.10.2 (2020-12-27)
|
150
|
-
|
151
|
-
### Bug fixes
|
152
|
-
|
153
|
-
* [#113](https://github.com/rubocop/rubocop-minitest/issues/113): Fix an error for `Minitest/AssertEqual` and some cops when using `assert` with block argument. ([@koic][])
|
154
|
-
|
155
|
-
## 0.10.1 (2020-07-25)
|
156
|
-
|
157
|
-
### Bug fixes
|
158
|
-
|
159
|
-
* [#106](https://github.com/rubocop/rubocop-minitest/issues/106): Fix an error for `Minitest/AssertOutput` when using gvar at top level. ([@koic][])
|
160
|
-
|
161
|
-
## 0.10.0 (2020-07-12)
|
162
|
-
|
163
|
-
### New features
|
164
|
-
|
165
|
-
* [#92](https://github.com/rubocop/rubocop-minitest/pull/92): Add new `Minitest/LiteralAsActualArgument` cop. ([@fatkodima][], [@tsmmark][])
|
166
|
-
* [#95](https://github.com/rubocop/rubocop-minitest/pull/95): Add new `Minitest/AssertionInLifecycleHook` cop. ([@fatkodima][])
|
167
|
-
* [#91](https://github.com/rubocop/rubocop-minitest/pull/91): Add new `Minitest/AssertInDelta` and `Minitest/RefuteInDelta` cops. ([@fatkodima][])
|
168
|
-
* [#89](https://github.com/rubocop/rubocop-minitest/pull/89): Add new `Minitest/TestMethodName` cop. ([@fatkodima][])
|
169
|
-
* [#83](https://github.com/rubocop/rubocop-minitest/pull/83): New cops `AssertPathExists` and `RefutePathExists` check for use of `assert_path_exists`/`refute_path_exists` instead of `assert(File.exist?(path))`/`refute(File.exist?(path))`. ([@fatkodima][])
|
170
|
-
* [#88](https://github.com/rubocop/rubocop-minitest/pull/88): Add new `Minitest/MultipleAssertions` cop. ([@fatkodima][])
|
171
|
-
* [#87](https://github.com/rubocop/rubocop-minitest/pull/87): Add new `Minitest/AssertSilent` cop. ([@fatkodima][])
|
172
|
-
* [#96](https://github.com/rubocop/rubocop-minitest/pull/96): Add new `Minitest/UnspecifiedException` cop. ([@fatkodima][])
|
173
|
-
* [#98](https://github.com/rubocop/rubocop-minitest/pull/98): Add new `Minitest/AssertOutput` cop. ([@fatkodima][])
|
174
|
-
* [#84](https://github.com/rubocop/rubocop-minitest/pull/84): New cops `AssertKindOf` and `RefuteKindOf` check for use of `assert_kind_of`/`refute_kind_of` instead of `assert(foo.kind_of?(Class))`/`refute(foo.kind_of?(Class))`. ([@fatkodima][])
|
175
|
-
* [#85](https://github.com/rubocop/rubocop-minitest/pull/85): Add autocorrect to `Rails/AssertEmptyLiteral` cop. ([@fatkodima][])
|
176
|
-
|
177
|
-
### Changes
|
178
|
-
|
179
|
-
* [#104](https://github.com/rubocop/rubocop-minitest/pull/104): Require RuboCop 0.87 or higher. ([@koic][])
|
180
|
-
|
181
|
-
## 0.9.0 (2020-04-13)
|
182
|
-
|
183
|
-
### Bug fixes
|
184
|
-
|
185
|
-
* [#75](https://github.com/rubocop/rubocop-minitest/issues/75): Fix a false negative for `Minitest/GlobalExpectations` when using global expectation methods with no arguments. ([@koic][])
|
186
|
-
|
187
|
-
### Changes
|
188
|
-
|
189
|
-
* [#73](https://github.com/rubocop/rubocop-minitest/issues/73): The Minitest department works on file names end with `_test.rb` by default. ([@koic][])
|
190
|
-
* [#77](https://github.com/rubocop/rubocop-minitest/pull/77): **(Compatibility)** Drop support for Ruby 2.3. ([@koic][])
|
191
|
-
|
192
|
-
## 0.8.1 (2020-04-06)
|
193
|
-
|
194
|
-
### Bug fixes
|
195
|
-
|
196
|
-
* [#72](https://github.com/rubocop/rubocop-minitest/pull/72): Fix some false negatives for `Minitest/GlobalExpectations`. ([@andrykonchin][])
|
197
|
-
|
198
|
-
## 0.8.0 (2020-03-24)
|
199
|
-
|
200
|
-
### New features
|
201
|
-
|
202
|
-
* [#66](https://github.com/rubocop/rubocop-minitest/issues/66): Support all expectations of `Minitest::Expectations` for `Minitest/GlobalExpectations` cop. ([@koic][])
|
203
|
-
|
204
|
-
### Bug fixes
|
205
|
-
|
206
|
-
* [#60](https://github.com/rubocop/rubocop-minitest/issues/60): Fix `Minitest/GlobalExpectations` autocorrection for chained methods. ([@tejasbubane][])
|
207
|
-
* [#69](https://github.com/rubocop/rubocop-minitest/pull/69): Fix a false negative for `Minitest/GlobalExpectations` cop when using a variable or a hash index for receiver. ([@koic][])
|
208
|
-
* [#71](https://github.com/rubocop/rubocop-minitest/pull/71): Fix a false negative for `Minitest/AssertEqual` when an argument is enclosed in redundant parentheses. ([@koic][])
|
209
|
-
|
210
|
-
## 0.7.0 (2020-03-09)
|
211
|
-
|
212
|
-
### New features
|
213
|
-
|
214
|
-
* [#60](https://github.com/rubocop/rubocop-minitest/issues/60): Add new cop `Minitest/GlobalExpectations` to check for deprecated global expectations. ([@tejasbubane][])
|
215
|
-
|
216
|
-
### Bug fixes
|
217
|
-
|
218
|
-
* [#58](https://github.com/rubocop/rubocop-minitest/pull/58): Fix a false negative for `Minitest/AssertMatch` and `Minitest/RefuteMatch` when an argument is enclosed in redundant parentheses. ([@koic][])
|
219
|
-
* [#59](https://github.com/rubocop/rubocop-minitest/pull/59): Fix a false negative for `Minitest/AssertRespondTo` and `Minitest/RefuteRespondTo` when an argument is enclosed in redundant parentheses. ([@koic][])
|
220
|
-
* [#61](https://github.com/rubocop/rubocop-minitest/pull/61): Fix a false negative for `Minitest/AssertInstanceOf` and `Minitest/RefuteInstanceOf` when an argument is enclosed in redundant parentheses. ([@koic][])
|
221
|
-
* [#62](https://github.com/rubocop/rubocop-minitest/pull/62): Fix a false negative for `Minitest/AssertEmpty` and `Minitest/RefuteEmpty` when an argument is enclosed in redundant parentheses. ([@koic][])
|
222
|
-
|
223
|
-
## 0.6.2 (2020-02-19)
|
224
|
-
|
225
|
-
### Bug fixes
|
226
|
-
|
227
|
-
* [#55](https://github.com/rubocop/rubocop-minitest/issues/55): Fix an error for `Minitest/AssertIncludes` when using local variable argument. ([@koic][])
|
228
|
-
|
229
|
-
## 0.6.1 (2020-02-18)
|
230
|
-
|
231
|
-
### Bug fixes
|
232
|
-
|
233
|
-
* [#52](https://github.com/rubocop/rubocop-minitest/issues/52): Make `Minitest/RefuteFalse` cop aware of `assert(!test)`. ([@koic][])
|
234
|
-
* [#52](https://github.com/rubocop/rubocop-minitest/issues/52): Fix a false negative for `Minitest/AssertIncludes` and `Minitest/RefuteIncludes` when an argument is enclosed in redundant parentheses. ([@koic][])
|
235
|
-
|
236
|
-
## 0.6.0 (2020-02-07)
|
237
|
-
|
238
|
-
### New features
|
239
|
-
|
240
|
-
* [#49](https://github.com/rubocop/rubocop-minitest/pull/49): New cops `AssertMatch` and `RefuteMatch` check for use of `assert_match`/`refute_match` instead of `assert(foo.match(bar))`/`refute(foo.match(bar))`. ([@fsateler][])
|
241
|
-
|
242
|
-
## 0.5.1 (2019-12-25)
|
243
|
-
|
244
|
-
### Bug fixes
|
245
|
-
|
246
|
-
* [#42](https://github.com/rubocop/rubocop-minitest/issues/42): Fix an incorrect autocorrect for some cops of `Minitest` department when using heredoc message. ([@koic][])
|
247
|
-
|
248
|
-
## 0.5.0 (2019-11-24)
|
249
|
-
|
250
|
-
### New features
|
251
|
-
|
252
|
-
* [#32](https://github.com/rubocop/rubocop-minitest/issues/32): Add new `Minitest/AssertEmptyLiteral` cop. ([@tejasbubane][])
|
253
|
-
|
254
|
-
## 0.4.1 (2019-11-10)
|
255
|
-
|
256
|
-
### Bug fixes
|
257
|
-
|
258
|
-
* [#39](https://github.com/rubocop/rubocop-minitest/issues/39): Fix an incorrect autocorrect for `Minitest/AssertRespondTo` and `Minitest/RefuteRespondTo` when using assertion method calling `respond_to` with receiver omitted. ([@koic][])
|
259
|
-
|
260
|
-
## 0.4.0 (2019-11-07)
|
261
|
-
|
262
|
-
### New features
|
263
|
-
|
264
|
-
* [#29](https://github.com/rubocop/rubocop-minitest/pull/29): Add new `Minitest/RefuteRespondTo` cop. ([@herwinw][])
|
265
|
-
* [#31](https://github.com/rubocop/rubocop-minitest/pull/31): Add new `Minitest/AssertEqual` cop. ([@herwinw][])
|
266
|
-
* [#34](https://github.com/rubocop/rubocop-minitest/pull/34): Add new `Minitest/AssertInstanceOf` cop. ([@abhaynikam][])
|
267
|
-
* [#35](https://github.com/rubocop/rubocop-minitest/pull/35): Add new `Minitest/RefuteInstanceOf` cop. ([@abhaynikam][])
|
268
|
-
|
269
|
-
### Bug fixes
|
270
|
-
|
271
|
-
* [#25](https://github.com/rubocop/rubocop-minitest/issues/25): Add `Enabled: true` to `Minitest` department config to suppress `Warning: Minitest does not support Enabled parameter`. ([@koic][])
|
272
|
-
|
273
|
-
## 0.3.0 (2019-10-13)
|
274
|
-
|
275
|
-
### New features
|
276
|
-
|
277
|
-
* [#15](https://github.com/rubocop/rubocop-minitest/pull/15): Add new `Minitest/RefuteIncludes` cop. ([@abhaynikam][])
|
278
|
-
* [#18](https://github.com/rubocop/rubocop-minitest/pull/18): Add new `Minitest/RefuteFalse` cop. ([@duduribeiro][])
|
279
|
-
* [#20](https://github.com/rubocop/rubocop-minitest/pull/20): Add new `Minitest/RefuteEmpty` cop. ([@abhaynikam][])
|
280
|
-
* [#21](https://github.com/rubocop/rubocop-minitest/pull/21): Add new `Minitest/RefuteEqual` cop. ([@duduribeiro][])
|
281
|
-
* [#27](https://github.com/rubocop/rubocop-minitest/pull/27): Add new `Minitest/AssertRespondTo` cop. ([@duduribeiro][])
|
282
|
-
|
283
|
-
### Bug fixes
|
284
|
-
|
285
|
-
* [#19](https://github.com/rubocop/rubocop-minitest/pull/19): Fix a false negative for `Minitest/AssertIncludes` when using `include` method in arguments of `assert` method. ([@abhaynikam][])
|
286
|
-
|
287
|
-
## 0.2.1 (2019-09-24)
|
288
|
-
|
289
|
-
### Bug fixes
|
290
|
-
|
291
|
-
* [#13](https://github.com/rubocop/rubocop-minitest/issues/13): Fix the execution target specified in `Include` parameter. ([@koic][])
|
292
|
-
|
293
|
-
## 0.2.0 (2019-09-21)
|
294
|
-
|
295
|
-
### New features
|
296
|
-
|
297
|
-
* [#11](https://github.com/rubocop/rubocop-minitest/pull/11): Add new `Minitest/RefuteNil` cop. ([@tejasbubane][])
|
298
|
-
* [#8](https://github.com/rubocop/rubocop-minitest/pull/8): Add new `Minitest/AssertTruthy` cop. ([@abhaynikam][])
|
299
|
-
* [#9](https://github.com/rubocop/rubocop-minitest/pull/9): Add new `Minitest/AssertIncludes` cop. ([@abhaynikam][])
|
300
|
-
* [#10](https://github.com/rubocop/rubocop-minitest/pull/10): Add new `Minitest/AssertEmpty` cop. ([@abhaynikam][])
|
301
|
-
|
302
|
-
## 0.1.0 (2019-09-01)
|
303
|
-
|
304
|
-
### New features
|
305
|
-
|
306
|
-
* Create RuboCop Minitest gem. ([@koic][])
|
307
|
-
* [#6](https://github.com/rubocop/rubocop-minitest/pull/6): Add new `Minitest/AssertNil` cop. ([@duduribeiro][])
|
308
|
-
|
309
|
-
[@koic]: https://github.com/koic
|
310
|
-
[@duduribeiro]: https://github.com/duduribeiro
|
311
|
-
[@tejasbubane]: https://github.com/tejasbubane
|
312
|
-
[@abhaynikam]: https://github.com/abhaynikam
|
313
|
-
[@herwinw]: https://github.com/herwinw
|
314
|
-
[@fsateler]: https://github.com/fsateler
|
315
|
-
[@andrykonchin]: https://github.com/andrykonchin
|
316
|
-
[@fatkodima]: https://github.com/fatkodima
|
317
|
-
[@tsmmark]: https://github.com/tsmmark
|
318
|
-
[@cstyles]: https://github.com/cstyles
|
319
|
-
[@ghiculescu]: https://github.com/ghiculescu
|
320
|
-
[@gi]: https://github.com/gi
|
321
|
-
[@ignacio-chiazzo]: https://github.com/ignacio-chiazzo
|
322
|
-
[@gjtorikian]: https://github.com/gjtorikian
|
323
|
-
[@ippachi]: https://github.com/ippachi
|
data/CONTRIBUTING.md
DELETED
@@ -1,69 +0,0 @@
|
|
1
|
-
# Contributing
|
2
|
-
|
3
|
-
If you discover issues, have ideas for improvements or new features,
|
4
|
-
please report them to the [issue tracker][1] of the repository or
|
5
|
-
submit a pull request. Please, try to follow these guidelines when you
|
6
|
-
do so.
|
7
|
-
|
8
|
-
## Issue reporting
|
9
|
-
|
10
|
-
* Check that the issue has not already been reported.
|
11
|
-
* Check that the issue has not already been fixed in the latest code
|
12
|
-
(a.k.a. `master`).
|
13
|
-
* Be clear, concise and precise in your description of the problem.
|
14
|
-
* Open an issue with a descriptive title and a summary in grammatically correct,
|
15
|
-
complete sentences.
|
16
|
-
* Include the output of `rubocop -V`:
|
17
|
-
|
18
|
-
```
|
19
|
-
$ rubocop -V
|
20
|
-
0.74.0 (using Parser 2.6.4.0, running on ruby 2.6.4 x86_64-darwin17)
|
21
|
-
```
|
22
|
-
|
23
|
-
* Include any relevant code to the issue summary.
|
24
|
-
|
25
|
-
## Pull requests
|
26
|
-
|
27
|
-
* Read [how to properly contribute to open source projects on GitHub][2].
|
28
|
-
* Fork the project.
|
29
|
-
* Use a topic/feature branch to easily amend a pull request later, if necessary.
|
30
|
-
* Write [good commit messages][3].
|
31
|
-
* Use the same coding conventions as the rest of the project.
|
32
|
-
* Commit and push until you are happy with your contribution.
|
33
|
-
* If your change has a corresponding open GitHub issue, prefix the commit message with `[Fix #github-issue-number]`.
|
34
|
-
* Make sure to add tests for it. This is important so I don't break it
|
35
|
-
in a future version unintentionally.
|
36
|
-
* Add an entry to the [Changelog](CHANGELOG.md) by creating a file `changelog/{type}_{some_description}.md`. See [changelog entry format](#changelog-entry-format) for details.
|
37
|
-
* Please try not to mess with the Rakefile, version, or history. If
|
38
|
-
you want to have your own version, or is otherwise necessary, that
|
39
|
-
is fine, but please isolate to its own commit so I can cherry-pick
|
40
|
-
around it.
|
41
|
-
* Make sure the test suite is passing and the code you wrote doesn't produce
|
42
|
-
RuboCop offenses (usually this is as simple as running `bundle exec rake`).
|
43
|
-
* [Squash related commits together][5].
|
44
|
-
* Open a [pull request][4] that relates to *only* one subject with a clear title
|
45
|
-
and description in grammatically correct, complete sentences.
|
46
|
-
|
47
|
-
### Changelog entry format
|
48
|
-
|
49
|
-
Here are a few examples:
|
50
|
-
|
51
|
-
```
|
52
|
-
* [#716](https://github.com/rubocop/rubocop-minitest/issues/716): Fixed a regression in the autocorrection logic of `MethodDefParentheses`. ([@bbatsov][])
|
53
|
-
* New cop `ElseLayout` checks for odd arrangement of code in the `else` branch of a conditional expression. ([@bbatsov][])
|
54
|
-
```
|
55
|
-
|
56
|
-
* Create one file `changelog/{type}_{some_description}.md`, where `type` is `new` (New feature), `fix` or `change`, and `some_description` is unique to avoid conflicts. Task `changelog:fix` (or `:new` or `:change`) can help you.
|
57
|
-
* Mark it up in [Markdown syntax][6].
|
58
|
-
* The entry line should start with `* ` (an asterisk and a space).
|
59
|
-
* If the change has a related GitHub issue (e.g. a bug fix for a reported issue), put a link to the issue as `[#123](https://github.com/rubocop/rubocop-minitest/issues/123): `.
|
60
|
-
* Describe the brief of the change. The sentence should end with a punctuation.
|
61
|
-
* At the end of the entry, add an implicit link to your GitHub user page as `([@username][])`.
|
62
|
-
* Alternatively, you may modify the CHANGELOG file directly, but this may result in conflicts later on. Also, if this is your first contribution to RuboCop Minitest project, add a link definition for the implicit link to the bottom of the changelog as `[@username]: https://github.com/username`.
|
63
|
-
|
64
|
-
[1]: https://github.com/rubocop/rubocop-minitest/issues
|
65
|
-
[2]: https://www.gun.io/blog/how-to-github-fork-branch-and-pull-request
|
66
|
-
[3]: https://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html
|
67
|
-
[4]: https://help.github.com/articles/about-pull-requests
|
68
|
-
[5]: http://gitready.com/advanced/2009/02/10/squashing-commits-with-rebase.html
|
69
|
-
[6]: https://daringfireball.net/projects/markdown/syntax
|
data/Gemfile
DELETED
@@ -1,16 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
source 'https://rubygems.org'
|
4
|
-
|
5
|
-
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
|
6
|
-
|
7
|
-
gemspec
|
8
|
-
|
9
|
-
gem 'bump', require: false
|
10
|
-
gem 'rake'
|
11
|
-
gem 'rubocop', github: 'rubocop/rubocop'
|
12
|
-
gem 'rubocop-performance', '~> 1.13.0'
|
13
|
-
gem 'yard', '~> 0.9'
|
14
|
-
|
15
|
-
local_gemfile = File.expand_path('Gemfile.local', __dir__)
|
16
|
-
eval_gemfile local_gemfile if File.exist?(local_gemfile)
|