8041253: Avoid redundant synonyms of NO_TEST

Reviewed-by: ksrini
This commit is contained in:
Jonathan Gibbons 2014-04-22 17:41:11 -07:00
parent 0a5665b53a
commit 187dbd343c
67 changed files with 81 additions and 183 deletions

View File

@ -91,9 +91,6 @@ public class MetaTag extends JavadocTester {
+ "content=\"" + m_dateFormat.format(new Date()) + "\">"}, + "content=\"" + m_dateFormat.format(new Date()) + "\">"},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[][] TEST2 = NO_TEST;
private static final String[][] NEGATED_TEST2 = { private static final String[][] NEGATED_TEST2 = {
//No keywords when -keywords is not used. //No keywords when -keywords is not used.
{ OUTPUT_DIR + "-2/p1/C1.html", { OUTPUT_DIR + "-2/p1/C1.html",
@ -132,8 +129,8 @@ public class MetaTag extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
MetaTag tester = new MetaTag(); MetaTag tester = new MetaTag();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.run(ARGS_NO_TIMESTAMP_NO_KEYWORDS, TEST2, NEGATED_TEST2); tester.run(ARGS_NO_TIMESTAMP_NO_KEYWORDS, NO_TEST, NEGATED_TEST2);
tester.printSummary(); tester.printSummary();
} }

View File

@ -97,9 +97,6 @@ public class PackagesHeader extends JavadocTester {
"p1", "p2"}; "p1", "p2"};
//Input for string search tests.
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
@ -107,9 +104,9 @@ public class PackagesHeader extends JavadocTester {
public static void main(String[] args) { public static void main(String[] args) {
JavadocTester tester = new PackagesHeader(); JavadocTester tester = new PackagesHeader();
tester.run(JAVADOC_ARGS1, TESTARRAY1, NEGATED_TEST); tester.run(JAVADOC_ARGS1, TESTARRAY1, NO_TEST);
tester.run(JAVADOC_ARGS2, TESTARRAY2, NEGATED_TEST); tester.run(JAVADOC_ARGS2, TESTARRAY2, NO_TEST);
tester.run(JAVADOC_ARGS3, TESTARRAY3, NEGATED_TEST); tester.run(JAVADOC_ARGS3, TESTARRAY3, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -37,7 +37,6 @@ public class TestAbsLinkPath extends JavadocTester {
private static final String BUG_ID = "4640745"; private static final String BUG_ID = "4640745";
private static final String[][] TEST = { private static final String[][] TEST = {
{"tmp/pkg1/C1.html", "C2.html"}}; {"tmp/pkg1/C1.html", "C2.html"}};
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS1 = private static final String[] ARGS1 =
new String[] { new String[] {
@ -54,7 +53,7 @@ public class TestAbsLinkPath extends JavadocTester {
public static void main(String[] args) { public static void main(String[] args) {
TestAbsLinkPath tester = new TestAbsLinkPath(); TestAbsLinkPath tester = new TestAbsLinkPath();
tester.run(ARGS1, NO_TEST, NO_TEST); tester.run(ARGS1, NO_TEST, NO_TEST);
tester.run(ARGS2, TEST, NEGATED_TEST); tester.run(ARGS2, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -49,16 +49,13 @@ public class TestAnnotationOptional extends JavadocTester {
"<a name=\"annotation.type.element.detail\">" "<a name=\"annotation.type.element.detail\">"
} }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestAnnotationOptional tester = new TestAnnotationOptional(); TestAnnotationOptional tester = new TestAnnotationOptional();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -38,7 +38,6 @@ public class TestBackSlashInLink extends JavadocTester {
private static final String BUG_ID = "4511110"; private static final String BUG_ID = "4511110";
private static final String[][] TEST = { private static final String[][] TEST = {
{BUG_ID + "/C.html", "src-html/C.html#line.7"}}; {BUG_ID + "/C.html", "src-html/C.html#line.7"}};
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "-d", BUG_ID, "-sourcepath", SRC_DIR,
@ -50,7 +49,7 @@ public class TestBackSlashInLink extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestBackSlashInLink tester = new TestBackSlashInLink(); TestBackSlashInLink tester = new TestBackSlashInLink();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -43,17 +43,13 @@ public class TestBadSourceFile extends JavadocTester {
"-Xdoclint:none", "-d", BUG_ID, SRC_DIR + "/C2.java" "-Xdoclint:none", "-d", BUG_ID, SRC_DIR + "/C2.java"
}; };
//Input for string search tests.
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestBadSourceFile tester = new TestBadSourceFile(); TestBadSourceFile tester = new TestBadSourceFile();
int exitCode = tester.run(ARGS, TEST, NEGATED_TEST); int exitCode = tester.run(ARGS, NO_TEST, NO_TEST);
tester.checkExitCode(0, exitCode); tester.checkExitCode(0, exitCode);
tester.printSummary(); tester.printSummary();
} }

View File

@ -36,8 +36,6 @@
public class TestBaseClass extends JavadocTester { public class TestBaseClass extends JavadocTester {
private static final String BUG_ID = "4197513"; private static final String BUG_ID = "4197513";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-sourcepath", SRC_DIR, "-sourcepath", SRC_DIR,
@ -50,7 +48,7 @@ public class TestBaseClass extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestBaseClass tester = new TestBaseClass(); TestBaseClass tester = new TestBaseClass();
if (tester.run(ARGS, TEST, NEGATED_TEST) != 0) { if (tester.run(ARGS, NO_TEST, NO_TEST) != 0) {
throw new Error("Javadoc failed to execute."); throw new Error("Javadoc failed to execute.");
} }
} }

View File

@ -41,7 +41,6 @@ public class TestBreakIterator extends JavadocTester {
private static final String[][] TEST = { private static final String[][] TEST = {
{BUG_ID + "/pkg/BreakIteratorTest.html", {BUG_ID + "/pkg/BreakIteratorTest.html",
"The class is empty (i.e. it has no members)."}}; "The class is empty (i.e. it has no members)."}};
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "-d", BUG_ID, "-sourcepath", SRC_DIR,
@ -53,7 +52,7 @@ public class TestBreakIterator extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestBreakIterator tester = new TestBreakIterator(); TestBreakIterator tester = new TestBreakIterator();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -51,7 +51,6 @@ public class TestCRLineSeparator extends JavadocTester {
" Line 2"} " Line 2"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -60,7 +59,7 @@ public class TestCRLineSeparator extends JavadocTester {
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
initFiles(new File(SRC_DIR), new File("."), "pkg"); initFiles(new File(SRC_DIR), new File("."), "pkg");
TestCRLineSeparator tester = new TestCRLineSeparator(); TestCRLineSeparator tester = new TestCRLineSeparator();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -53,7 +53,6 @@ public class TestClassCrossReferences extends JavadocTester {
"<dd><code>toString</code>&nbsp;in class&nbsp;<code>java.lang.Object</code></dd>\n" + "<dd><code>toString</code>&nbsp;in class&nbsp;<code>java.lang.Object</code></dd>\n" +
"</dl>"} "</dl>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "-d", BUG_ID, "-sourcepath", SRC_DIR,
@ -66,7 +65,7 @@ public class TestClassCrossReferences extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestClassCrossReferences tester = new TestClassCrossReferences(); TestClassCrossReferences tester = new TestClassCrossReferences();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -38,8 +38,6 @@ public class TestCmndLineClass extends JavadocTester {
private static final String OUTPUT_DIR1 = "4506980-tmp1"; private static final String OUTPUT_DIR1 = "4506980-tmp1";
private static final String OUTPUT_DIR2 = "4506980-tmp2"; private static final String OUTPUT_DIR2 = "4506980-tmp2";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS1 = private static final String[] ARGS1 =
new String[] { new String[] {
"-d", OUTPUT_DIR1, "-sourcepath", SRC_DIR, "-d", OUTPUT_DIR1, "-sourcepath", SRC_DIR,
@ -70,8 +68,8 @@ public class TestCmndLineClass extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestCmndLineClass tester = new TestCmndLineClass(); TestCmndLineClass tester = new TestCmndLineClass();
tester.run(ARGS1, TEST, NEGATED_TEST); tester.run(ARGS1, NO_TEST, NO_TEST);
tester.run(ARGS2, TEST, NEGATED_TEST); tester.run(ARGS2, NO_TEST, NO_TEST);
tester.runDiffs(FILES_TO_DIFF); tester.runDiffs(FILES_TO_DIFF);
} }

View File

@ -36,7 +36,6 @@
public class TestConstantValuesPage extends JavadocTester { public class TestConstantValuesPage extends JavadocTester {
private static final String BUG_ID = "4681599"; private static final String BUG_ID = "4681599";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = { private static final String[][] NEGATED_TEST = {
{NOTICE_OUTPUT, "constant-values.html..."} {NOTICE_OUTPUT, "constant-values.html..."}
}; };
@ -50,7 +49,7 @@ public class TestConstantValuesPage extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestConstantValuesPage tester = new TestConstantValuesPage(); TestConstantValuesPage tester = new TestConstantValuesPage();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, NO_TEST, NEGATED_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -53,7 +53,6 @@ public class TestConstructorIndent extends JavadocTester {
"</dl>" "</dl>"
} }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -61,7 +60,7 @@ public class TestConstructorIndent extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestConstructorIndent tester = new TestConstructorIndent(); TestConstructorIndent tester = new TestConstructorIndent();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -92,15 +92,13 @@ public class TestDeprecatedDocs extends JavadocTester {
"<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"}, "<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestDeprecatedDocs tester = new TestDeprecatedDocs(); TestDeprecatedDocs tester = new TestDeprecatedDocs();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -50,8 +50,6 @@ public class TestDocEncoding extends JavadocTester {
"pkg" "pkg"
}; };
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = { private static final String[][] NEGATED_TEST = {
{BUG_ID + "/stylesheet.css", {BUG_ID + "/stylesheet.css",
"body {\n" + "body {\n" +
@ -64,7 +62,7 @@ public class TestDocEncoding extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestDocEncoding tester = new TestDocEncoding(); TestDocEncoding tester = new TestDocEncoding();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, NO_TEST, NEGATED_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -44,10 +44,6 @@ public class TestDocErrorReporter extends JavadocTester {
SRC_DIR + "/TestDocErrorReporter.java" SRC_DIR + "/TestDocErrorReporter.java"
}; };
//Input for string search tests.
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = NO_TEST;
//Input for Javadoc return code test. //Input for Javadoc return code test.
private static final int EXPECTED_EXIT_CODE = 1; private static final int EXPECTED_EXIT_CODE = 1;
@ -57,7 +53,7 @@ public class TestDocErrorReporter extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestDocErrorReporter tester = new TestDocErrorReporter(); TestDocErrorReporter tester = new TestDocErrorReporter();
int actualExitCode = tester.run(ARGS, TEST, NEGATED_TEST); int actualExitCode = tester.run(ARGS, NO_TEST, NO_TEST);
tester.checkExitCode(EXPECTED_EXIT_CODE, actualExitCode); tester.checkExitCode(EXPECTED_EXIT_CODE, actualExitCode);
tester.printSummary(); tester.printSummary();
} }

View File

@ -45,7 +45,6 @@ public class TestDocFileDir extends JavadocTester {
{BUG_ID + "-1/pkg/doc-files/testfile.txt", {BUG_ID + "-1/pkg/doc-files/testfile.txt",
"This doc file did not get trashed."} "This doc file did not get trashed."}
}; };
private static final String[][] NEGATED_TEST1 = NO_TEST;
private static final String[] FILE_TEST2 = { private static final String[] FILE_TEST2 = {
BUG_ID + "-2/pkg/doc-files/subdir-used1" + BUG_ID + "-2/pkg/doc-files/subdir-used1" +
@ -64,7 +63,6 @@ public class TestDocFileDir extends JavadocTester {
{"pkg/doc-files/testfile.txt", {"pkg/doc-files/testfile.txt",
"This doc file did not get trashed."} "This doc file did not get trashed."}
}; };
private static final String[][] NEGATED_TEST0 = {};
//Output dir = Input Dir //Output dir = Input Dir
private static final String[] ARGS1 = private static final String[] ARGS1 =
@ -95,9 +93,9 @@ public class TestDocFileDir extends JavadocTester {
public static void main(String[] args) { public static void main(String[] args) {
TestDocFileDir tester = new TestDocFileDir(); TestDocFileDir tester = new TestDocFileDir();
copyDir(SRC_DIR + "/pkg", "."); copyDir(SRC_DIR + "/pkg", ".");
tester.run(ARGS0, TEST0, NEGATED_TEST0); tester.run(ARGS0, TEST0, NO_TEST);
copyDir(SRC_DIR + "/pkg", BUG_ID + "-1"); copyDir(SRC_DIR + "/pkg", BUG_ID + "-1");
tester.run(ARGS1, TEST1, NEGATED_TEST1); tester.run(ARGS1, TEST1, NO_TEST);
tester.run(ARGS2, NO_TEST, NO_TEST, FILE_TEST2, FILE_NEGATED_TEST2); tester.run(ARGS2, NO_TEST, NO_TEST, FILE_TEST2, FILE_NEGATED_TEST2);
tester.printSummary(); tester.printSummary();
} }

View File

@ -50,7 +50,6 @@ public class TestDocRootInlineTag extends JavadocTester {
{BUG_ID + "/index-all.html", "My package page is " + {BUG_ID + "/index-all.html", "My package page is " +
"<a href=\"./pkg/package-summary.html\">here</a>"} "<a href=\"./pkg/package-summary.html\">here</a>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-bottom", "The value of @docRoot is \"{@docRoot}\"", "-bottom", "The value of @docRoot is \"{@docRoot}\"",
@ -65,7 +64,7 @@ public class TestDocRootInlineTag extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestDocRootInlineTag tester = new TestDocRootInlineTag(); TestDocRootInlineTag tester = new TestDocRootInlineTag();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -36,7 +36,6 @@
public class TestEmptyClass extends JavadocTester { public class TestEmptyClass extends JavadocTester {
private static final String OUTPUT_DIR = "tmp"; private static final String OUTPUT_DIR = "tmp";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = { private static final String[][] NEGATED_TEST = {
//The overview tree should not link to classes that were not documented //The overview tree should not link to classes that were not documented
@ -60,7 +59,7 @@ public class TestEmptyClass extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestEmptyClass tester = new TestEmptyClass(); TestEmptyClass tester = new TestEmptyClass();
int exitCode = tester.run(ARGS, TEST, NEGATED_TEST); int exitCode = tester.run(ARGS, NO_TEST, NEGATED_TEST);
tester.printSummary(); tester.printSummary();
if (exitCode != 0) { if (exitCode != 0) {
throw new Error("Error found while executing Javadoc"); throw new Error("Error found while executing Javadoc");

View File

@ -46,7 +46,6 @@ public class TestEnclosingClass extends JavadocTester {
private static final String[][] TEST = { private static final String[][] TEST = {
{BUG_ID + "/pkg/MyClass.MyInterface.html", "Enclosing class:"} {BUG_ID + "/pkg/MyClass.MyInterface.html", "Enclosing class:"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -54,7 +53,7 @@ public class TestEnclosingClass extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestEnclosingClass tester = new TestEnclosingClass(); TestEnclosingClass tester = new TestEnclosingClass();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -36,7 +36,6 @@
public class TestEncoding extends JavadocTester { public class TestEncoding extends JavadocTester {
private static final String BUG_ID = "4661481"; private static final String BUG_ID = "4661481";
private static final String[][] TEST = NO_TEST;
//If ??? is found in the output, the source file was not read with the correct encoding setting. //If ??? is found in the output, the source file was not read with the correct encoding setting.
private static final String[][] NEGATED_TEST = { private static final String[][] NEGATED_TEST = {
@ -54,7 +53,7 @@ public class TestEncoding extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestEncoding tester = new TestEncoding(); TestEncoding tester = new TestEncoding();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, NO_TEST, NEGATED_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -50,10 +50,6 @@ public class TestExternalOverridenMethod extends JavadocTester {
"<a href=\"http://java.sun.com/j2se/1.4.1/docs/api/java/io/DataInput.html?is-external=true\" " + "<a href=\"http://java.sun.com/j2se/1.4.1/docs/api/java/io/DataInput.html?is-external=true\" " +
"title=\"class or interface in java.io\">DataInput</a></code></dd>"}}; "title=\"class or interface in java.io\">DataInput</a></code></dd>"}};
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "-d", BUG_ID, "-sourcepath", SRC_DIR,
@ -67,7 +63,7 @@ public class TestExternalOverridenMethod extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestExternalOverridenMethod tester = new TestExternalOverridenMethod(); TestExternalOverridenMethod tester = new TestExternalOverridenMethod();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -56,11 +56,9 @@ public class TestGroupOption extends JavadocTester {
}; };
//Input for string search tests. //Input for string search tests.
private static final String[][] TEST1 = NO_TEST;
private static final String[][] NEGATED_TEST1 = {{WARNING_OUTPUT, "-group"}}; private static final String[][] NEGATED_TEST1 = {{WARNING_OUTPUT, "-group"}};
private static final String[][] TEST2 = {{WARNING_OUTPUT, "-group"}}; private static final String[][] TEST2 = {{WARNING_OUTPUT, "-group"}};
private static final String[][] NEGATED_TEST2 = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -69,12 +67,12 @@ public class TestGroupOption extends JavadocTester {
public static void main(String[] args) { public static void main(String[] args) {
//Make sure the warning is not printed when -group is used correctly. //Make sure the warning is not printed when -group is used correctly.
TestGroupOption tester = new TestGroupOption(); TestGroupOption tester = new TestGroupOption();
tester.run(ARGS1, TEST1, NEGATED_TEST1); tester.run(ARGS1, NO_TEST, NEGATED_TEST1);
tester.printSummary(); tester.printSummary();
//Make sure the warning is printed when -group is not used correctly. //Make sure the warning is printed when -group is not used correctly.
tester = new TestGroupOption(); tester = new TestGroupOption();
tester.run(ARGS2, TEST2, NEGATED_TEST2); tester.run(ARGS2, TEST2, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -108,10 +108,8 @@ public class TestHeadings extends JavadocTester {
// Overview Summary // Overview Summary
{BUG_ID + "/overview-summary.html", {BUG_ID + "/overview-summary.html",
"<title>Overview</title>" "<title>Overview</title>"
}, }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -119,7 +117,7 @@ public class TestHeadings extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestHeadings tester = new TestHeadings(); TestHeadings tester = new TestHeadings();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -42,8 +42,6 @@ public class TestHelpFile extends JavadocTester {
SRC_DIR + "/TestHelpFile.java" SRC_DIR + "/TestHelpFile.java"
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[][] TEST = { private static final String[][] TEST = {
{BUG_ID + "/help-doc.html", {BUG_ID + "/help-doc.html",
"<a href=\"constant-values.html\">Constant Field Values</a>" "<a href=\"constant-values.html\">Constant Field Values</a>"
@ -56,7 +54,7 @@ public class TestHelpFile extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestHelpFile tester = new TestHelpFile(); TestHelpFile tester = new TestHelpFile();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -86,14 +86,12 @@ public class TestHelpOption extends JavadocTester {
{STANDARD_OUTPUT, "-stylesheetfile "}, {STANDARD_OUTPUT, "-stylesheetfile "},
{STANDARD_OUTPUT, "-docencoding "}, {STANDARD_OUTPUT, "-docencoding "},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[][] TEST2 = { private static final String[][] TEST2 = {
{BUG_ID + "/TestHelpOption.html", {BUG_ID + "/TestHelpOption.html",
"<li><a href=\"help-doc.html\">Help</a></li>" "<li><a href=\"help-doc.html\">Help</a></li>"
}, },
}; };
private static final String[][] NEGATED_TEST2 = NO_TEST;
//The help option should not crash the doclet. //The help option should not crash the doclet.
private static final int EXPECTED_EXIT_CODE = 0; private static final int EXPECTED_EXIT_CODE = 0;
@ -104,9 +102,9 @@ public class TestHelpOption extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestHelpOption tester = new TestHelpOption(); TestHelpOption tester = new TestHelpOption();
int actualExitCode = tester.run(ARGS, TEST, NEGATED_TEST); int actualExitCode = tester.run(ARGS, TEST, NO_TEST);
tester.checkExitCode(EXPECTED_EXIT_CODE, actualExitCode); tester.checkExitCode(EXPECTED_EXIT_CODE, actualExitCode);
tester.run(ARGS2, TEST2, NEGATED_TEST2); tester.run(ARGS2, TEST2, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -36,7 +36,6 @@
public class TestHiddenMembers extends JavadocTester { public class TestHiddenMembers extends JavadocTester {
private static final String BUG_ID = "4492178"; private static final String BUG_ID = "4492178";
private static final String[][] TEST = NO_TEST;
//We should not inherit any members from BaseClass because they are all overriden and hidden //We should not inherit any members from BaseClass because they are all overriden and hidden
//(declared as private). //(declared as private).
@ -56,7 +55,7 @@ public class TestHiddenMembers extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestHiddenMembers tester = new TestHiddenMembers(); TestHiddenMembers tester = new TestHiddenMembers();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, NO_TEST, NEGATED_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -36,8 +36,6 @@
public class TestHrefInDocComment extends JavadocTester { public class TestHrefInDocComment extends JavadocTester {
private static final String BUG_ID = "4638015"; private static final String BUG_ID = "4638015";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"}; "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"};
@ -48,7 +46,7 @@ public class TestHrefInDocComment extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestHrefInDocComment tester = new TestHrefInDocComment(); TestHrefInDocComment tester = new TestHrefInDocComment();
if (tester.run(ARGS, TEST, NEGATED_TEST) != 0) { if (tester.run(ARGS, NO_TEST, NO_TEST) != 0) {
throw new Error("Javadoc failed to execute properly with given source."); throw new Error("Javadoc failed to execute properly with given source.");
} }

View File

@ -44,7 +44,6 @@ public class TestHtmlComments extends JavadocTester {
}; };
//Input for string search tests. //Input for string search tests.
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = { private static final String[][] NEGATED_TEST = {
{BUG_ID + "/C.html", {BUG_ID + "/C.html",
"<!-- ============ FIELD DETAIL =========== -->"} "<!-- ============ FIELD DETAIL =========== -->"}
@ -56,7 +55,7 @@ public class TestHtmlComments extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestHtmlComments tester = new TestHtmlComments(); TestHtmlComments tester = new TestHtmlComments();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, NO_TEST, NEGATED_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -425,7 +425,6 @@ public class TestHtmlTableTags extends JavadocTester {
">Description</th>" ">Description</th>"
} }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -433,7 +432,7 @@ public class TestHtmlTableTags extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestHtmlTableTags tester = new TestHtmlTableTags(); TestHtmlTableTags tester = new TestHtmlTableTags();
tester.run(ARGS, TABLE_TAGS_TEST, NEGATED_TEST); tester.run(ARGS, TABLE_TAGS_TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -51,7 +51,6 @@ public class TestIndentation extends JavadocTester {
"\n" + "\n" +
" throws java.lang.Exception" } " throws java.lang.Exception" }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -59,7 +58,7 @@ public class TestIndentation extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestIndentation tester = new TestIndentation(); TestIndentation tester = new TestIndentation();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -81,7 +81,6 @@ public class TestIndex extends JavadocTester {
"<dd>&nbsp;</dd>\n" + "<dd>&nbsp;</dd>\n" +
"</dl>"}, "</dl>"},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -89,7 +88,7 @@ public class TestIndex extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestIndex tester = new TestIndex(); TestIndex tester = new TestIndex();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -44,7 +44,6 @@ public class TestInlineLinkLabel extends JavadocTester {
{BUG_ID + "/pkg/C1.html" , {BUG_ID + "/pkg/C1.html" ,
"<a href=\"../pkg/C2.html\" title=\"class in pkg\"><code>Here is a link to a class</code></a>"} "<a href=\"../pkg/C2.html\" title=\"class in pkg\"><code>Here is a link to a class</code></a>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"}; "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"};
@ -55,7 +54,7 @@ public class TestInlineLinkLabel extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestInlineLinkLabel tester = new TestInlineLinkLabel(); TestInlineLinkLabel tester = new TestInlineLinkLabel();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -114,15 +114,13 @@ public class TestJavascript extends JavadocTester {
" }"}, " }"},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestJavascript tester = new TestJavascript(); TestJavascript tester = new TestJavascript();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -48,7 +48,6 @@ public class LeadingSpaces extends JavadocTester {
" 6\n" + " 6\n" +
" 7"} " 7"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "-d", BUG_ID, "-sourcepath", SRC_DIR,
@ -60,7 +59,7 @@ public class LeadingSpaces extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
LeadingSpaces tester = new LeadingSpaces(); LeadingSpaces tester = new LeadingSpaces();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -51,15 +51,13 @@ public class TestLegacyTaglet extends JavadocTester {
"<td bgcolor=\"yellow\">Tag in Method.</td></tr></table></DD>"} "<td bgcolor=\"yellow\">Tag in Method.</td></tr></table></DD>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestLegacyTaglet tester = new TestLegacyTaglet(); TestLegacyTaglet tester = new TestLegacyTaglet();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
if (tester.getErrorOutput().contains("NullPointerException")) { if (tester.getErrorOutput().contains("NullPointerException")) {
throw new AssertionError("javadoc threw NullPointerException"); throw new AssertionError("javadoc threw NullPointerException");
} }

View File

@ -86,7 +86,6 @@ public class TestLinkOption extends JavadocTester {
"title=\"class or interface in pkg\"><code>Class C</code></a>." "title=\"class or interface in pkg\"><code>Class C</code></a>."
} }
}; };
private static final String[][] NEGATED_TEST2 = NO_TEST;
/* /*
* Create the documentation using the -link option, vary the behavior with * Create the documentation using the -link option, vary the behavior with
* both trailing and no trailing slash. We are only interested in ensuring * both trailing and no trailing slash. We are only interested in ensuring
@ -122,7 +121,8 @@ public class TestLinkOption extends JavadocTester {
public static void main(String[] args) { public static void main(String[] args) {
TestLinkOption tester = new TestLinkOption(); TestLinkOption tester = new TestLinkOption();
tester.run(ARGS1, TEST1, NEGATED_TEST1); tester.run(ARGS1, TEST1, NEGATED_TEST1);
tester.run(ARGS2, TEST2, NEGATED_TEST2); tester.run(ARGS1, TEST1, NEGATED_TEST1);
tester.run(ARGS2, TEST2, NO_TEST);
tester.runJavadoc(createArguments(true)); // with trailing slash tester.runJavadoc(createArguments(true)); // with trailing slash
tester.runJavadoc(createArguments(false)); // without trailing slash tester.runJavadoc(createArguments(false)); // without trailing slash
tester.printSummary(); tester.printSummary();

View File

@ -40,7 +40,6 @@ public class TestLinkToSerialForm extends JavadocTester {
{BUG_ID + "/serialized-form.html", "<a name=\"pkg.C\">"}, {BUG_ID + "/serialized-form.html", "<a name=\"pkg.C\">"},
{BUG_ID + "/pkg/C.html", "<a href=\"../serialized-form.html#pkg.C\">"} {BUG_ID + "/pkg/C.html", "<a href=\"../serialized-form.html#pkg.C\">"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"}; "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"};
@ -51,7 +50,7 @@ public class TestLinkToSerialForm extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestLinkToSerialForm tester = new TestLinkToSerialForm(); TestLinkToSerialForm tester = new TestLinkToSerialForm();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -89,15 +89,13 @@ public class TestLiteralCodeInPre extends JavadocTester {
" and so it goes.</div>" } " and so it goes.</div>" }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestLiteralCodeInPre tester = new TestLiteralCodeInPre(); TestLiteralCodeInPre tester = new TestLiteralCodeInPre();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -67,7 +67,6 @@ public class TestMemberSummary extends JavadocTester {
"</a>" "</a>"
}, },
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -75,7 +74,7 @@ public class TestMemberSummary extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestMemberSummary tester = new TestMemberSummary(); TestMemberSummary tester = new TestMemberSummary();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -36,8 +36,6 @@
public class TestModifier extends JavadocTester { public class TestModifier extends JavadocTester {
private static final String BUG_ID = "4210388"; private static final String BUG_ID = "4210388";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-sourcepath", SRC_DIR, "-sourcepath", SRC_DIR,
@ -50,7 +48,7 @@ public class TestModifier extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestModifier tester = new TestModifier(); TestModifier tester = new TestModifier();
if (tester.run(ARGS, TEST, NEGATED_TEST) != 0) { if (tester.run(ARGS, NO_TEST, NO_TEST) != 0) {
throw new Error("Javadoc error occured during execution."); throw new Error("Javadoc error occured during execution.");
} }
} }

View File

@ -65,7 +65,6 @@ public class TestNavigation extends JavadocTester {
"<!-- -->\n" + "<!-- -->\n" +
"</a>"} "</a>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -73,7 +72,7 @@ public class TestNavigation extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestNavigation tester = new TestNavigation(); TestNavigation tester = new TestNavigation();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -50,7 +50,6 @@ public class TestNestedGenerics extends JavadocTester {
"(java.util.Map&lt;A, java.util.Map&lt;A, A&gt;&gt;)</code></a></div>" "(java.util.Map&lt;A, java.util.Map&lt;A, A&gt;&gt;)</code></a></div>"
} }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -58,7 +57,7 @@ public class TestNestedGenerics extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestNestedGenerics tester = new TestNestedGenerics(); TestNestedGenerics tester = new TestNestedGenerics();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -77,7 +77,6 @@ public class TestNestedInlineTag extends JavadocTester {
} }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = private static final String[] ARGS =
new String[] { new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "-d", BUG_ID, "-sourcepath", SRC_DIR,
@ -93,7 +92,7 @@ public class TestNestedInlineTag extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestNestedInlineTag tester = new TestNestedInlineTag(); TestNestedInlineTag tester = new TestNestedInlineTag();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -49,15 +49,13 @@ public class TestOptions extends JavadocTester {
"<div class=\"aboutLanguage\">Test footer</div>"} "<div class=\"aboutLanguage\">Test footer</div>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestOptions tester = new TestOptions(); TestOptions tester = new TestOptions();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -51,7 +51,6 @@ public class TestOverridenMethodDocCopy extends JavadocTester {
"BaseClass</a></code></span>" "BaseClass</a></code></span>"
} }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -59,7 +58,7 @@ public class TestOverridenMethodDocCopy extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestOverridenMethodDocCopy tester = new TestOverridenMethodDocCopy(); TestOverridenMethodDocCopy tester = new TestOverridenMethodDocCopy();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -57,8 +57,6 @@ public class TestPackageDeprecation extends JavadocTester {
"<li><a href=\"#package\">Deprecated Packages</a></li>" "<li><a href=\"#package\">Deprecated Packages</a></li>"
} }
}; };
private static final String[][] TEST2 = NO_TEST;
private static final String[][] NEGATED_TEST1 = NO_TEST;
private static final String[][] NEGATED_TEST2 = { private static final String[][] NEGATED_TEST2 = {
{BUG_ID + "-2/overview-summary.html", "pkg1"}, {BUG_ID + "-2/overview-summary.html", "pkg1"},
{BUG_ID + "-2/allclasses-frame.html", "FooDepr"} {BUG_ID + "-2/allclasses-frame.html", "FooDepr"}
@ -70,8 +68,8 @@ public class TestPackageDeprecation extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestPackageDeprecation tester = new TestPackageDeprecation(); TestPackageDeprecation tester = new TestPackageDeprecation();
tester.run(ARGS1, TEST1, NEGATED_TEST1); tester.run(ARGS1, TEST1, NO_TEST);
tester.run(ARGS2, TEST2, NEGATED_TEST2); tester.run(ARGS2, NO_TEST, NEGATED_TEST2);
if ((new java.io.File(BUG_ID + "-2/pkg1/" + if ((new java.io.File(BUG_ID + "-2/pkg1/" +
"package-summary.html")).exists()) { "package-summary.html")).exists()) {
throw new Error("Test Fails: packages summary should not be" + throw new Error("Test Fails: packages summary should not be" +

View File

@ -67,7 +67,6 @@ public class TestParamTaglet extends JavadocTester {
}, },
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -75,7 +74,7 @@ public class TestParamTaglet extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestParamTaglet tester = new TestParamTaglet(); TestParamTaglet tester = new TestParamTaglet();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -96,10 +96,7 @@ public class TestRelativeLinks extends JavadocTester {
//PACKAGE OVERVIEW //PACKAGE OVERVIEW
{BUG_ID + "/overview-summary.html", {BUG_ID + "/overview-summary.html",
"<a href=\"./pkg/relative-package-link.html\">relative package link</a>"}, "<a href=\"./pkg/relative-package-link.html\">relative package link</a>"},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -107,7 +104,7 @@ public class TestRelativeLinks extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestRelativeLinks tester = new TestRelativeLinks(); TestRelativeLinks tester = new TestRelativeLinks();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -48,7 +48,6 @@ public class TestReturnTag extends JavadocTester {
{WARNING_OUTPUT, {WARNING_OUTPUT,
"warning - @return tag cannot be used in method with void return type."} "warning - @return tag cannot be used in method with void return type."}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* Trigger warning message when return tag is used on a void method. * Trigger warning message when return tag is used on a void method.
@ -63,7 +62,7 @@ public class TestReturnTag extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestReturnTag tester = new TestReturnTag(); TestReturnTag tester = new TestReturnTag();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -49,7 +49,6 @@ public class TestSerialVersionUID extends JavadocTester {
private static final String[][] TEST = { private static final String[][] TEST = {
{OUTPUT_DIR + "/serialized-form.html", "-111111111111111L"} {OUTPUT_DIR + "/serialized-form.html", "-111111111111111L"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -57,7 +56,7 @@ public class TestSerialVersionUID extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestSerialVersionUID tester = new TestSerialVersionUID(); TestSerialVersionUID tester = new TestSerialVersionUID();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -36,7 +36,6 @@
public class TestSimpleTagExclude extends JavadocTester { public class TestSimpleTagExclude extends JavadocTester {
private static final String BUG_ID = "4628181"; private static final String BUG_ID = "4628181";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = { private static final String[][] NEGATED_TEST = {
{BUG_ID + "/DummyClass.html", "todo"} {BUG_ID + "/DummyClass.html", "todo"}
}; };
@ -51,7 +50,7 @@ public class TestSimpleTagExclude extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestSimpleTagExclude tester = new TestSimpleTagExclude(); TestSimpleTagExclude tester = new TestSimpleTagExclude();
if (tester.run(ARGS, TEST, NEGATED_TEST) != 0) { if (tester.run(ARGS, NO_TEST, NEGATED_TEST) != 0) {
throw new Error("Javadoc failed to execute."); throw new Error("Javadoc failed to execute.");
} }
tester.printSummary(); tester.printSummary();

View File

@ -52,7 +52,6 @@ public class TestSimpleTagInherit extends JavadocTester {
"<dt><span class=\"simpleTagLabel\"><em>Custom:</em></span></dt>\n" + "<dt><span class=\"simpleTagLabel\"><em>Custom:</em></span></dt>\n" +
"<dd>doc for BaseClass method</dd>" } "<dd>doc for BaseClass method</dd>" }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -60,7 +59,7 @@ public class TestSimpleTagInherit extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestSimpleTagInherit tester = new TestSimpleTagInherit(); TestSimpleTagInherit tester = new TestSimpleTagInherit();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -41,8 +41,6 @@ public class TestSourceTab extends JavadocTester {
private static final String TMP_SRC_DIR = "tmpSrc"; private static final String TMP_SRC_DIR = "tmpSrc";
private static final String OUTPUT_DIR1 = BUG_ID + "-tabLengthEight"; private static final String OUTPUT_DIR1 = BUG_ID + "-tabLengthEight";
private static final String OUTPUT_DIR2 = BUG_ID + "-tabLengthFour"; private static final String OUTPUT_DIR2 = BUG_ID + "-tabLengthFour";
private static final String[][] TEST = NO_TEST;
private static final String[][] NEGATED_TEST = NO_TEST;
//Run Javadoc on a source file with that is indented with a single tab per line //Run Javadoc on a source file with that is indented with a single tab per line
private static final String[] ARGS1 = private static final String[] ARGS1 =
@ -77,8 +75,8 @@ public class TestSourceTab extends JavadocTester {
*/ */
public static void main(String[] args) throws IOException { public static void main(String[] args) throws IOException {
TestSourceTab tester = new TestSourceTab(); TestSourceTab tester = new TestSourceTab();
tester.run(ARGS1, TEST, NEGATED_TEST); tester.run(ARGS1, NO_TEST, NO_TEST);
tester.run(ARGS2, TEST, NEGATED_TEST); tester.run(ARGS2, NO_TEST, NO_TEST);
tester.runDiffs(FILES_TO_DIFF); tester.runDiffs(FILES_TO_DIFF);
} }

View File

@ -48,7 +48,6 @@ public class TestSummaryHeading extends JavadocTester {
private static final String[][] TEST = { private static final String[][] TEST = {
{BUG_ID + "/C.html", "<h3>Method Summary</h3>"} {BUG_ID + "/C.html", "<h3>Method Summary</h3>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -56,7 +55,7 @@ public class TestSummaryHeading extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestSummaryHeading tester = new TestSummaryHeading(); TestSummaryHeading tester = new TestSummaryHeading();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -42,7 +42,6 @@ public class TestSuperClassInSerialForm extends JavadocTester {
"<a href=\"pkg/SubClass.html\" title=\"class in pkg\">pkg.SubClass</a> extends <a href=\"pkg/SuperClass.html\" title=\"class in pkg\">SuperClass</a>"} "<a href=\"pkg/SubClass.html\" title=\"class in pkg\">pkg.SubClass</a> extends <a href=\"pkg/SuperClass.html\" title=\"class in pkg\">SuperClass</a>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = new String[] { private static final String[] ARGS = new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg" "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"
}; };
@ -53,7 +52,7 @@ public class TestSuperClassInSerialForm extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestSuperClassInSerialForm tester = new TestSuperClassInSerialForm(); TestSuperClassInSerialForm tester = new TestSuperClassInSerialForm();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -39,7 +39,6 @@ public class TestTagMisuse extends JavadocTester {
{WARNING_OUTPUT, "warning - Tag @return cannot be used in constructor documentation."}, {WARNING_OUTPUT, "warning - Tag @return cannot be used in constructor documentation."},
{WARNING_OUTPUT, "warning - Tag @throws cannot be used in inline documentation."}, {WARNING_OUTPUT, "warning - Tag @throws cannot be used in inline documentation."},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = new String[] { private static final String[] ARGS = new String[] {
"-Xdoclint:none", "-d", BUG_ID, SRC_DIR + "/TestTagMisuse.java" "-Xdoclint:none", "-d", BUG_ID, SRC_DIR + "/TestTagMisuse.java"
}; };
@ -50,7 +49,7 @@ public class TestTagMisuse extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestTagMisuse tester = new TestTagMisuse(); TestTagMisuse tester = new TestTagMisuse();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -59,13 +59,11 @@ public class TestTaglets extends JavadocTester {
"<dd>my only method is <a href=\"C.html#method--\"><code>here" + "<dd>my only method is <a href=\"C.html#method--\"><code>here" +
"</code></a></dd></dl>"} "</code></a></dd></dl>"}
}; };
private static final String[][] NEGATED_TEST_4654308 = NO_TEST;
private static final String[][] TEST_4767038 = new String[][] { private static final String[][] TEST_4767038 = new String[][] {
{"4767038/Child.html", {"4767038/Child.html",
"This is the first sentence."} "This is the first sentence."}
}; };
private static final String[][] NEGATED_TEST_4767038 = NO_TEST;
/** /**
@ -74,10 +72,10 @@ public class TestTaglets extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestTaglets tester = new TestTaglets(); TestTaglets tester = new TestTaglets();
tester.run(ARGS_4654308, TEST_4654308, NEGATED_TEST_4654308); tester.run(ARGS_4654308, TEST_4654308, NO_TEST);
tester.printSummary(); tester.printSummary();
tester = new TestTaglets(); tester = new TestTaglets();
tester.run(ARGS_4767038, TEST_4767038, NEGATED_TEST_4767038); tester.run(ARGS_4767038, TEST_4767038, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -40,7 +40,6 @@ public class TestThrowsHead extends JavadocTester {
private static final String[][] TEST = { private static final String[][] TEST = {
{BUG_ID + "/C.html", "<dt><span class=\"throwsLabel\">Throws:</span>"} {BUG_ID + "/C.html", "<dt><span class=\"throwsLabel\">Throws:</span>"}
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = new String[] { private static final String[] ARGS = new String[] {
"-d", BUG_ID, SRC_DIR + "/C.java" "-d", BUG_ID, SRC_DIR + "/C.java"
}; };
@ -51,7 +50,7 @@ public class TestThrowsHead extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestThrowsHead tester = new TestThrowsHead(); TestThrowsHead tester = new TestThrowsHead();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -56,7 +56,6 @@ public class TestThrowsTag extends JavadocTester {
"<dd><code><a href=\"../pkg/T8.html\" title=\"class in pkg\">T8</a></code> - the fourth inherited throws tag.</dd>" "<dd><code><a href=\"../pkg/T8.html\" title=\"class in pkg\">T8</a></code> - the fourth inherited throws tag.</dd>"
}, },
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -64,7 +63,7 @@ public class TestThrowsTag extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestThrowsTag tester = new TestThrowsTag(); TestThrowsTag tester = new TestThrowsTag();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -51,7 +51,6 @@ public class TestTitleInHref extends JavadocTester {
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = new String[] { private static final String[] ARGS = new String[] {
"-d", BUG_ID, "-sourcepath", SRC_DIR, "-d", BUG_ID, "-sourcepath", SRC_DIR,
"-linkoffline", "http://java.sun.com/j2se/1.4/docs/api", "-linkoffline", "http://java.sun.com/j2se/1.4/docs/api",
@ -64,7 +63,7 @@ public class TestTitleInHref extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestTitleInHref tester = new TestTitleInHref(); TestTitleInHref tester = new TestTitleInHref();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -70,7 +70,6 @@ public class TestTopOption extends JavadocTester {
{BUG_ID + "/help-doc.html", {BUG_ID + "/help-doc.html",
"TOP TEXT"}, "TOP TEXT"},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -78,7 +77,7 @@ public class TestTopOption extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestTopOption tester = new TestTopOption(); TestTopOption tester = new TestTopOption();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -43,7 +43,6 @@ public class TestTypeAnnotations extends JavadocTester {
}; };
//Input for string search tests. //Input for string search tests.
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[][] TEST = { private static final String[][] TEST = {
// Test for type annotations on Class Extends (ClassExtends.java). // Test for type annotations on Class Extends (ClassExtends.java).
{BUG_ID + "/typeannos/MyClass.html", {BUG_ID + "/typeannos/MyClass.html",
@ -383,7 +382,7 @@ public class TestTypeAnnotations extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestTypeAnnotations tester = new TestTypeAnnotations(); TestTypeAnnotations tester = new TestTypeAnnotations();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -84,7 +84,6 @@ public class TestTypeParameters extends JavadocTester {
"<a href=\"../pkg/Foo4.html\" title=\"class in pkg\">Foo4</a>&gt;&gt;&gt;" "<a href=\"../pkg/Foo4.html\" title=\"class in pkg\">Foo4</a>&gt;&gt;&gt;"
} }
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
@ -92,8 +91,8 @@ public class TestTypeParameters extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestTypeParameters tester = new TestTypeParameters(); TestTypeParameters tester = new TestTypeParameters();
tester.run(ARGS1, TEST1, NEGATED_TEST); tester.run(ARGS1, TEST1, NO_TEST);
tester.run(ARGS2, TEST2, NEGATED_TEST); tester.run(ARGS2, TEST2, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -41,7 +41,6 @@ public class TestWarnBadParamNames extends JavadocTester {
{WARNING_OUTPUT, "warning - @param argument \"IDontExist\" is not a parameter name."}, {WARNING_OUTPUT, "warning - @param argument \"IDontExist\" is not a parameter name."},
{WARNING_OUTPUT, "warning - Parameter \"arg\" is documented more than once."}, {WARNING_OUTPUT, "warning - Parameter \"arg\" is documented more than once."},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
private static final String[] ARGS = new String[] { private static final String[] ARGS = new String[] {
"-Xdoclint:none", "-d", BUG_ID, SRC_DIR + "/C.java" "-Xdoclint:none", "-d", BUG_ID, SRC_DIR + "/C.java"
}; };
@ -52,7 +51,7 @@ public class TestWarnBadParamNames extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestWarnBadParamNames tester = new TestWarnBadParamNames(); TestWarnBadParamNames tester = new TestWarnBadParamNames();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -74,9 +74,6 @@ public class TestWarnings extends JavadocTester {
"<a href=\"../pkg/X.html#f\"><code>f</code></a><br/>"}, "<a href=\"../pkg/X.html#f\"><code>f</code></a><br/>"},
}; };
private static final String[][] NEGATED_TEST2 = NO_TEST;
/** /**
* The entry point of the test. * The entry point of the test.
* @param args the array of command line arguments. * @param args the array of command line arguments.
@ -84,7 +81,8 @@ public class TestWarnings extends JavadocTester {
public static void main(String[] args) { public static void main(String[] args) {
TestWarnings tester = new TestWarnings(); TestWarnings tester = new TestWarnings();
tester.run(ARGS, TEST, NEGATED_TEST); tester.run(ARGS, TEST, NEGATED_TEST);
tester.run(ARGS2, TEST2, NEGATED_TEST2); tester.run(ARGS, TEST, NEGATED_TEST);
tester.run(ARGS2, TEST2, NO_TEST);
tester.printSummary(); tester.printSummary();
} }

View File

@ -53,7 +53,6 @@ public class TestXOption extends JavadocTester {
{STANDARD_OUTPUT, "-Xdoclint "}, {STANDARD_OUTPUT, "-Xdoclint "},
{STANDARD_OUTPUT, "-Xdoclint:"}, {STANDARD_OUTPUT, "-Xdoclint:"},
}; };
private static final String[][] NEGATED_TEST = NO_TEST;
//The help option should not crash the doclet. //The help option should not crash the doclet.
private static final int EXPECTED_EXIT_CODE = 0; private static final int EXPECTED_EXIT_CODE = 0;
@ -64,7 +63,7 @@ public class TestXOption extends JavadocTester {
*/ */
public static void main(String[] args) { public static void main(String[] args) {
TestXOption tester = new TestXOption(); TestXOption tester = new TestXOption();
int actualExitCode = tester.run(ARGS, TEST, NEGATED_TEST); int actualExitCode = tester.run(ARGS, TEST, NO_TEST);
tester.checkExitCode(EXPECTED_EXIT_CODE, actualExitCode); tester.checkExitCode(EXPECTED_EXIT_CODE, actualExitCode);
tester.printSummary(); tester.printSummary();
} }