[tests] javadoc highlighting tests merger and cleanup

This commit is contained in:
Roman Shevchenko
2016-03-07 16:02:31 +01:00
parent ec4b8b92eb
commit f759a56f8f
43 changed files with 195 additions and 337 deletions

View File

@@ -0,0 +1,10 @@
/**
* @author me
*/
abstract class Foo {
/**
* @param <warning descr="'@param i' tag description is missing">i</warning>
* @param <warning descr="'@param j' tag description is missing">j</warning>
*/
public abstract void foo(int i, int j);
}

View File

@@ -0,0 +1,7 @@
/**
* Test.
* @deprecated You bet.
* <warning descr="Duplicate @deprecated tag">@deprecated</warning> Gotcha.
*/
class Foo {
}

View File

@@ -0,0 +1,9 @@
class Test {
/**
* Test.
* @param s my string
* <warning descr="Duplicate @param tag for parameter 's'">@param</warning> s another string
*/
void test(String s) {
}
}

View File

@@ -0,0 +1,10 @@
class Test {
/**
* Test.
* @return my string
* <warning descr="Duplicate @return tag">@return</warning> another string
*/
String test() {
return "";
}
}

View File

@@ -0,0 +1,8 @@
class Test {
/**
* Test.
* @serial something
* <warning descr="Duplicate @serial tag">@serial</warning> something else
*/
private int a;
}

View File

@@ -0,0 +1,9 @@
class Test {
/**
* Test.
* @throws java.lang.Exception in case of problems
* <warning descr="Duplicate @throws or @exception tag for exception 'java.lang.Exception'">@exception</warning> java.lang.Exception in case of other problems
*/
void test() throws java.lang.Exception {
}
}

View File

@@ -0,0 +1,6 @@
enum Foo {
;
Foo() {
}
}

View File

@@ -0,0 +1,9 @@
class Foo {
/**
* description
*
* @param i this is a parameter
* @param <T> type of object to do something with.
*/
public <T> void foo(T i){}
}

View File

@@ -0,0 +1,11 @@
class Test {
private int myFoo;
public int getFoo() {
return myFoo;
}
public void setFoo(int foo) {
myFoo = foo;
}
}

View File

@@ -0,0 +1,8 @@
class Test {
/**
* @throws ArrayIndexOutOfBoundsException in some case
* @throws ArrayIndexOutOfBoundsException and in some other case
*/
void foo() throws ArrayIndexOutOfBoundsException {
}
}

View File

@@ -3,7 +3,7 @@
* <i>The Unicode Standard</i></a>
*/
class LinksInJavaDoc {
// Since Java 7 classloading is parallel on parallel capable classloader (http://docs.oracle.com/javase/7/docs/technotes/guides/lang/cl-mt.html)
// Since Java 7 classloading is parallel on parallel capable classloader (http://docs.oracle.com/javase/7/docs/tech-notes/guides/lang/cl-mt.html)
// Parallel classloading avoids deadlocks like https://youtrack.jetbrains.com/issue/IDEA-131621,
// Use mailto:webmaster@jetbrains.com to report abuse
}

View File

@@ -0,0 +1,8 @@
class Test {
/**
* @throws java.io.IOException exception in some case
* @throws Exception exception in other case
*/
public void foo() throws Exception, java.io.IOException {
}
}

View File

@@ -0,0 +1,20 @@
/**
* @author me
*/
abstract class Foo {
/**
* @param i this is a parameter
*/
public abstract void foo(int i);
}
/**
* @author me
*/
class Bar extends Foo {
/**
*/
public void foo(int i) {
i++;
}
}

View File

@@ -0,0 +1,7 @@
class Test {
<warning descr="Required tag '@throws' java.io.IOException is missing">/**</warning>
* @throws java.lang.ArrayIndexOutOfBoundsException in some case
*/
void foo() throws java.io.IOException, java.lang.ArrayIndexOutOfBoundsException {
}
}