mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-03-22 15:19:59 +07:00
IDEADEV-2514
This commit is contained in:
@@ -262,6 +262,9 @@ inspection.javadoc.method.problem.descriptor=Description is missing in {0} tag f
|
||||
inspection.javadoc.method.problem.descriptor1=Description is missing in {0} tag.
|
||||
inspection.javadoc.method.problem.descriptor2={0} tag description is missing.
|
||||
inspection.javadoc.method.problem.descriptor3=Required tag {0} is missing for parameter {1}
|
||||
inspection.javadoc.problem.duplicate.param=Duplicate @param tag for parameter ''{0}''
|
||||
inspection.javadoc.problem.duplicate.throws=Duplicate @throws or @exception tag for exception ''{0}''
|
||||
inspection.javadoc.problem.duplicate.tag=Duplicate @{0} tag
|
||||
|
||||
inspection.export.results.abstract=abstract
|
||||
inspection.export.results.static=static
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<problems>
|
||||
<problem>
|
||||
<file>Foo.java</file>
|
||||
<line>4</line>
|
||||
<description>Duplicate @deprecated tag</description>
|
||||
</problem>
|
||||
</problems>
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
/**
|
||||
* Test.
|
||||
* @deprecated You bet.
|
||||
* @deprecated Gotcha.
|
||||
*/
|
||||
class Foo {
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<problems>
|
||||
<problem>
|
||||
<file>Foo.java</file>
|
||||
<line>5</line>
|
||||
<description>Duplicate @param tag for parameter 's'</description>
|
||||
</problem>
|
||||
</problems>
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
class Test {
|
||||
/**
|
||||
* Test.
|
||||
* @param s my string
|
||||
* @param s another string
|
||||
*/
|
||||
void test(String s) {
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<problems>
|
||||
<problem>
|
||||
<file>Foo.java</file>
|
||||
<line>5</line>
|
||||
<description>Duplicate @return tag</description>
|
||||
</problem>
|
||||
</problems>
|
||||
@@ -0,0 +1,9 @@
|
||||
class Test {
|
||||
/**
|
||||
* Test.
|
||||
* @return my string
|
||||
* @return another string
|
||||
*/
|
||||
String test() {
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<problems>
|
||||
<problem>
|
||||
<file>Foo.java</file>
|
||||
<line>5</line>
|
||||
<description>Duplicate @serial tag</description>
|
||||
</problem>
|
||||
</problems>
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
class Test {
|
||||
/**
|
||||
* Test.
|
||||
* @serial something
|
||||
* @serial something else
|
||||
*/
|
||||
private int a;
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<problems>
|
||||
<problem>
|
||||
<file>Foo.java</file>
|
||||
<line>5</line>
|
||||
<description>Duplicate @throws tag for exception 'java.lang.Exception'</description>
|
||||
</problem>
|
||||
</problems>
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
class Test {
|
||||
/**
|
||||
* Test.
|
||||
* @throws java.lang.Exception in case of problems
|
||||
* @exception java.lang.Exception in case of other problems
|
||||
*/
|
||||
void test() throws java.lang.Exception {
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
package com.intellij.codeInspection;
|
||||
|
||||
import com.intellij.codeInspection.javaDoc.JavaDocInspection;
|
||||
|
||||
/**
|
||||
* Created by IntelliJ IDEA.
|
||||
* User: yole
|
||||
* Date: 22.09.2005
|
||||
* Time: 20:24:19
|
||||
* To change this template use File | Settings | File Templates.
|
||||
*/
|
||||
public class JavaDocInspectionTest extends InspectionTestCase {
|
||||
private JavaDocInspection myTool;
|
||||
|
||||
protected void setUp() throws Exception {
|
||||
super.setUp();
|
||||
myTool = new JavaDocInspection();
|
||||
myTool.initialize(getManager());
|
||||
}
|
||||
|
||||
private void doTest() throws Exception {
|
||||
doTest("javaDocInspection/" + getTestName(false), myTool);
|
||||
}
|
||||
|
||||
public void testDuplicateParam() throws Exception {
|
||||
doTest();
|
||||
}
|
||||
|
||||
public void testDuplicateReturn() throws Exception {
|
||||
doTest();
|
||||
}
|
||||
|
||||
// tests for duplicate class tags
|
||||
public void testDuplicateDeprecated() throws Exception {
|
||||
doTest();
|
||||
}
|
||||
|
||||
// tests for duplicate field tags
|
||||
public void testDuplicateSerial() throws Exception {
|
||||
doTest();
|
||||
}
|
||||
|
||||
public void testDuplicateThrows() throws Exception {
|
||||
doTest();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user