langtools/test/com/sun/javadoc/testDocEncoding/TestDocEncoding.java
changeset 24399 af1a0220d0fa
parent 24072 e7549dcbc4af
child 30730 d3ce7619db2c
equal deleted inserted replaced
24398:601a611d0aee 24399:af1a0220d0fa
    29  * @test
    29  * @test
    30  * @bug      8000743
    30  * @bug      8000743
    31  * @summary  Run tests on -docencoding to see if the value is
    31  * @summary  Run tests on -docencoding to see if the value is
    32              used for stylesheet as well.
    32              used for stylesheet as well.
    33  * @author   jayashree viswanathan
    33  * @author   jayashree viswanathan
    34  * @library  ../lib/
    34  * @library  ../lib
    35  * @build    JavadocTester TestDocEncoding
    35  * @build    JavadocTester
    36  * @run main TestDocEncoding
    36  * @run main TestDocEncoding
    37  */
    37  */
    38 
    38 
    39 public class TestDocEncoding extends JavadocTester {
    39 public class TestDocEncoding extends JavadocTester {
    40 
    40 
    41     //Javadoc arguments.
    41     public static void main(String... args) throws Exception {
    42     private static final String[] ARGS = new String[] {
    42         TestDocEncoding tester = new TestDocEncoding();
    43         "-d", OUTPUT_DIR,
    43         tester.runTests();
    44         "-docencoding", "Cp930",
    44     }
    45         "-sourcepath", SRC_DIR,
       
    46         "-notimestamp",
       
    47         "pkg"
       
    48     };
       
    49 
    45 
    50     private static final String[][] NEGATED_TEST = {
    46     @Test
    51         { "stylesheet.css",
    47     void test() {
    52             "body {\n" +
    48         javadoc("-d", "out",
    53             "    background-color:#ffffff;"}
    49                 "-docencoding", "Cp930",
    54     };
    50                 "-sourcepath", testSrc,
       
    51                 "-notimestamp",
       
    52                 "pkg");
       
    53         checkExit(Exit.OK);
    55 
    54 
    56     /**
    55         checkOutput("stylesheet.css", false,
    57      * The entry point of the test.
    56                 "body {\n"
    58      * @param args the array of command line arguments.
    57                 + "    background-color:#ffffff;");
    59      */
       
    60     public static void main(String[] args) {
       
    61         TestDocEncoding tester = new TestDocEncoding();
       
    62         tester.run(ARGS, NO_TEST, NEGATED_TEST);
       
    63         tester.printSummary();
       
    64     }
    58     }
    65 }
    59 }
    66 
    60