Skip to content

Commit d813f4e

Browse files
authored
Merge pull request #9 from green-code-initiative/ISSUE_4
[EC66] deprecation of EC66 rule for Python
2 parents 2e86afb + 16cae3e commit d813f4e

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1919

2020
### Deleted
2121

22+
- [#4](https://github.com/green-code-initiative/ecoCode-python/issues/4) Deprecate rule EC66 for Python because not applicable (see details inside issue)
23+
2224
## [1.4.0] - 2023-08-08
2325

2426
### Added

src/main/java/fr/greencodeinitiative/python/checks/AvoidDoubleQuoteCheck.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@
2323
import org.sonar.plugins.python.api.tree.StringLiteral;
2424
import org.sonar.plugins.python.api.tree.Tree;
2525

26+
/**
27+
* @deprecated not applicable for Python
28+
* (check discussion inside issue https://github.com/green-code-initiative/ecoCode-python/issues/4)
29+
*/
30+
@Deprecated(forRemoval = true)
2631
@Rule(key = "EC66")
2732
public class AvoidDoubleQuoteCheck extends PythonSubscriptionCheck {
2833
public static final String MESSAGE_RULE = "Avoid using quotation mark (\"), prefer using simple quote (')";

src/test/java/fr/greencodeinitiative/python/checks/AvoidDoubleQuoteTest.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
import org.junit.Test;
2121
import org.sonar.python.checks.utils.PythonCheckVerifier;
2222

23+
@Deprecated
2324
public class AvoidDoubleQuoteTest {
2425
@Test
2526
public void test() {

0 commit comments

Comments
 (0)