diff --git a/java/java-analysis-api/resources/messages/JavaAnalysisBundle.properties b/java/java-analysis-api/resources/messages/JavaAnalysisBundle.properties index 640f989428c3..c4efcde17205 100644 --- a/java/java-analysis-api/resources/messages/JavaAnalysisBundle.properties +++ b/java/java-analysis-api/resources/messages/JavaAnalysisBundle.properties @@ -216,8 +216,8 @@ inspection.implicit.subclass.display.name=Final declaration can't be overridden inspection.implicit.subclass.extendable=Make ''{0}'' overridable inspection.implicit.subclass.make.class.extendable=Make class ''{0}'' {1,choice,0#|1#and method {2} |1 -Reports cases when a module name contradicts Java Platform Module System recommendations. -

One of the recommendations - is to avoid using digits at the end of module names.

+Reports module names in module-info.java that violate the Java Platform Module System +recommendation + to avoid encoding version information in module names by ending the name with one or more digits.

Example:


-module foo1.bar2 {}
+ module foo.bar2 {}
+
+

After the quick-fix is applied:

+

+  module foo.bar {}
 
diff --git a/java/java-tests/testSrc/com/intellij/java/codeInspection/JavaModuleNamingTest.kt b/java/java-tests/testSrc/com/intellij/java/codeInspection/JavaModuleNamingTest.kt index a91fcb6467a6..2fd5058f3159 100644 --- a/java/java-tests/testSrc/com/intellij/java/codeInspection/JavaModuleNamingTest.kt +++ b/java/java-tests/testSrc/com/intellij/java/codeInspection/JavaModuleNamingTest.kt @@ -10,9 +10,9 @@ class JavaModuleNamingTest : LightJava9ModulesCodeInsightFixtureTestCase() { myFixture.enableInspections(JavaModuleNamingInspection()) } - fun testSimple() = highlighting("""module foo1.bar { }""") + fun testSimple() = highlighting("""module foo1.bar { }""") fun testSuppress() = highlighting("""@SuppressWarnings("module") module foo1.bar { }""") - fun testDevanagariDigitsAreBannedToo() = highlighting("""module foo१.bar { }""") + fun testDevanagariDigitsAreBannedToo() = highlighting("""module foo१.bar { }""") fun testMiddleDigitsAllowed() = highlighting("""module f0o.b4r { }""") fun testFix() {