Skip to content

Commit 170e25f

Browse files
committed
[ISSUE 4] deprecation of EC66 rule for Python
1 parent 7b1463e commit 170e25f

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
@@ -18,6 +18,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1818

1919
### Deleted
2020

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

2325
### 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)