langtools/test/com/sun/javadoc/testHtmlComments/TestHtmlComments.java
changeset 24399 af1a0220d0fa
parent 24072 e7549dcbc4af
child 30730 d3ce7619db2c
--- a/langtools/test/com/sun/javadoc/testHtmlComments/TestHtmlComments.java	Fri May 09 23:31:05 2014 +0200
+++ b/langtools/test/com/sun/javadoc/testHtmlComments/TestHtmlComments.java	Fri May 09 15:37:12 2014 -0700
@@ -27,32 +27,26 @@
  * @summary  The field detail comment should not show up in the output if there
  *           are no fields to document.
  * @author   jamieh
- * @library  ../lib/
+ * @library  ../lib
  * @build    JavadocTester
- * @build    TestHtmlComments
  * @run main TestHtmlComments
  */
 
 public class TestHtmlComments extends JavadocTester {
 
-    //Javadoc arguments.
-    private static final String[] ARGS = new String[] {
-        "-d", OUTPUT_DIR, "-sourcepath", SRC_DIR, SRC_DIR + "/C.java"
-    };
+    public static void main(String... args) throws Exception {
+        TestHtmlComments tester = new TestHtmlComments();
+        tester.runTests();
+    }
 
-    //Input for string search tests.
-    private static final String[][] NEGATED_TEST = {
-        { "C.html",
-            "<!-- ============ FIELD DETAIL =========== -->"}
-    };
+    @Test
+    void run() {
+        javadoc("-d", "out",
+                "-sourcepath", testSrc,
+                testSrc("C.java"));
+        checkExit(Exit.OK);
 
-    /**
-     * The entry point of the test.
-     * @param args the array of command line arguments.
-     */
-    public static void main(String[] args) {
-        TestHtmlComments tester = new TestHtmlComments();
-        tester.run(ARGS, NO_TEST, NEGATED_TEST);
-        tester.printSummary();
+        checkOutput("C.html", false,
+            "<!-- ============ FIELD DETAIL =========== -->");
     }
 }