File tree Expand file tree Collapse file tree 2 files changed +29
-5
lines changed Expand file tree Collapse file tree 2 files changed +29
-5
lines changed Original file line number Diff line number Diff line change @@ -1946,13 +1946,26 @@ Checks for common mistakes in example descriptions.
1946
1946
This cop will correct docstrings that begin with 'should' and 'it'.
1947
1947
This cop will also look for insufficient examples and call them out.
1948
1948
1949
- The autocorrect is experimental - use with care! It can be configured
1950
- with CustomTransform (e.g. have => has) and IgnoredWords (e.g. only).
1951
-
1952
1949
Use the DisallowedExamples setting to prevent unclear or insufficient
1953
1950
descriptions. Please note that this config will not be treated as
1954
1951
case sensitive.
1955
1952
1953
+ [#safety-rspecexamplewording]
1954
+ === Safety
1955
+
1956
+ The autocorrect is experimental - use with care! It can be configured
1957
+ with CustomTransform (e.g. have => has) and IgnoredWords (e.g. only).
1958
+
1959
+ While the autocorrect will not break your code (it only modifies test
1960
+ description strings, not the actual test logic), it may produce
1961
+ grammatically incorrect English in some cases. Always review the diff
1962
+ when using autocorrect to ensure the descriptions remain natural and
1963
+ accurate.
1964
+
1965
+ This is not classified as an unsafe autocorrect because it does not
1966
+ affect code behavior, but manual review of changes is strongly
1967
+ recommended.
1968
+
1956
1969
[#examples-rspecexamplewording]
1957
1970
=== Examples
1958
1971
Original file line number Diff line number Diff line change @@ -10,8 +10,19 @@ module RSpec
10
10
#
11
11
# @see http://betterspecs.org/#should
12
12
#
13
- # The autocorrect is experimental - use with care! It can be configured
14
- # with CustomTransform (e.g. have => has) and IgnoredWords (e.g. only).
13
+ # @safety
14
+ # The autocorrect is experimental - use with care! It can be configured
15
+ # with CustomTransform (e.g. have => has) and IgnoredWords (e.g. only).
16
+ #
17
+ # While the autocorrect will not break your code (it only modifies test
18
+ # description strings, not the actual test logic), it may produce
19
+ # grammatically incorrect English in some cases. Always review the diff
20
+ # when using autocorrect to ensure the descriptions remain natural and
21
+ # accurate.
22
+ #
23
+ # This is not classified as an unsafe autocorrect because it does not
24
+ # affect code behavior, but manual review of changes is strongly
25
+ # recommended.
15
26
#
16
27
# Use the DisallowedExamples setting to prevent unclear or insufficient
17
28
# descriptions. Please note that this config will not be treated as
You can’t perform that action at this time.
0 commit comments