Modify rule S104, S138, S1151, S1752, S1753: Adapt titles and messages (#3932)
This commit is contained in:
parent
bd5a06a98b
commit
32b7982d41
@ -1,3 +1,3 @@
|
||||
{
|
||||
"title": "Files should not have too many lines"
|
||||
|
||||
}
|
||||
|
@ -6,7 +6,9 @@ ifdef::env-github,rspecator-view[]
|
||||
== Implementation Specification
|
||||
(visible only on this page)
|
||||
|
||||
include::../message.adoc[]
|
||||
=== Message
|
||||
|
||||
File "XXXX" has {0} lines of code, which is greater than {1} authorized. Split it into smaller files.
|
||||
|
||||
include::../parameters.adoc[]
|
||||
|
||||
|
@ -1,3 +1,3 @@
|
||||
{
|
||||
"title": "\"SELECT WHEN\" clauses should not have too many lines"
|
||||
"title": "\"SELECT WHEN\" clauses should not have too many lines of code"
|
||||
}
|
||||
|
@ -4,6 +4,9 @@ The ``++SELECT++`` statement should be used only to clearly define some new bran
|
||||
|
||||
=== Noncompliant code example
|
||||
|
||||
With the default threshold of 5:
|
||||
|
||||
|
||||
[source,rpg]
|
||||
----
|
||||
C SELECT
|
||||
@ -64,7 +67,9 @@ ifdef::env-github,rspecator-view[]
|
||||
== Implementation Specification
|
||||
(visible only on this page)
|
||||
|
||||
include::../message.adoc[]
|
||||
=== Message
|
||||
|
||||
Reduce this "[WHEN|OTHER]" number of lines of code from {} to at most {}, for example by extracting code into a [method|subroutine|function].
|
||||
|
||||
include::../parameters.adoc[]
|
||||
|
||||
|
@ -1,3 +1,3 @@
|
||||
{
|
||||
"title": "Subroutines should not have too manylines"
|
||||
"title": "Subroutines should not have too many lines of code"
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
== Why is this an issue?
|
||||
|
||||
``++DO++`` blocks that contain too many lines are difficult to read and understand.
|
||||
``++DO++`` blocks that contain too many lines of code are difficult to read and understand.
|
||||
|
||||
|
||||
Above a specific threshold, it is strongly advised to refactor the contents of the ``++DO++`` block into multiple, well-named subroutines or subfunctions, each of which focuses on a well-defined task. Those smaller subroutines will not only be easier to understand, but probably also easier to test.
|
||||
@ -13,7 +13,7 @@ ifdef::env-github,rspecator-view[]
|
||||
|
||||
=== Message
|
||||
|
||||
Reduce the number of lines in this "DO" block from XX to at most YY
|
||||
Reduce the number of lines of code in this "DO" block from XX to at most YY
|
||||
|
||||
|
||||
=== Parameters
|
||||
|
@ -1,6 +1,6 @@
|
||||
== Why is this an issue?
|
||||
|
||||
``++IF++`` blocks that contain too many lines are difficult to read and understand.
|
||||
``++IF++`` blocks that contain too many lines of code are difficult to read and understand.
|
||||
|
||||
|
||||
Above a specific threshold, it is strongly advised to refactor the contents of the ``++IF++`` block into multiple, well-named subroutines or subfunctions, each of which focuses on a well-defined task. Those smaller subroutines will not only be easier to understand, but probably also easier to test.
|
||||
@ -13,7 +13,7 @@ ifdef::env-github,rspecator-view[]
|
||||
|
||||
=== Message
|
||||
|
||||
Reduce the number of lines in this "IF" block from XX to at most YY
|
||||
Reduce the number of lines of code in this "IF" block from XX to at most YY
|
||||
|
||||
|
||||
=== Parameters
|
||||
|
Loading…
x
Reference in New Issue
Block a user