langtools/test/com/sun/javadoc/testDeprecatedDocs/TestDeprecatedDocs.java
changeset 23971 f5ff1f5a8dee
parent 23139 612191246a7d
child 24065 fc4022e50129
equal deleted inserted replaced
23970:76f4acb11952 23971:f5ff1f5a8dee
     1 /*
     1 /*
     2  * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    40     private static final String[] ARGS = new String[] {
    40     private static final String[] ARGS = new String[] {
    41         "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"
    41         "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"
    42     };
    42     };
    43 
    43 
    44     private static final String TARGET_FILE  =
    44     private static final String TARGET_FILE  =
    45         BUG_ID + FS + "deprecated-list.html";
    45         BUG_ID + "/deprecated-list.html";
    46 
    46 
    47     private static final String TARGET_FILE2  =
    47     private static final String TARGET_FILE2  =
    48         BUG_ID + FS + "pkg" + FS + "DeprecatedClassByAnnotation.html";
    48         BUG_ID + "/pkg/DeprecatedClassByAnnotation.html";
    49 
    49 
    50     //Input for string search tests.
    50     //Input for string search tests.
    51     private static final String[][] TEST = {
    51     private static final String[][] TEST = {
    52         {TARGET_FILE, "annotation_test1 passes"},
    52         {TARGET_FILE, "annotation_test1 passes"},
    53         {TARGET_FILE, "annotation_test2 passes"},
    53         {TARGET_FILE, "annotation_test2 passes"},
    73         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation"},
    73         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation"},
    74         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation()"},
    74         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation()"},
    75         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation.method()"},
    75         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation.method()"},
    76         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation.field"},
    76         {TARGET_FILE, "pkg.DeprecatedClassByAnnotation.field"},
    77 
    77 
    78         {TARGET_FILE2, "<pre>@Deprecated" + NL +
    78         {TARGET_FILE2, "<pre>@Deprecated\n" +
    79                  "public class <span class=\"typeNameLabel\">DeprecatedClassByAnnotation</span>" + NL +
    79                  "public class <span class=\"typeNameLabel\">DeprecatedClassByAnnotation</span>\n" +
    80                  "extends java.lang.Object</pre>"},
    80                  "extends java.lang.Object</pre>"},
    81 
    81 
    82         {TARGET_FILE2, "<pre>@Deprecated" + NL +
    82         {TARGET_FILE2, "<pre>@Deprecated\n" +
    83                  "public&nbsp;int field</pre>" + NL +
    83                  "public&nbsp;int field</pre>\n" +
    84                  "<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"},
    84                  "<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"},
    85 
    85 
    86         {TARGET_FILE2, "<pre>@Deprecated" + NL +
    86         {TARGET_FILE2, "<pre>@Deprecated\n" +
    87                  "public&nbsp;DeprecatedClassByAnnotation()</pre>" + NL +
    87                  "public&nbsp;DeprecatedClassByAnnotation()</pre>\n" +
    88                  "<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"},
    88                  "<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"},
    89 
    89 
    90         {TARGET_FILE2, "<pre>@Deprecated" + NL +
    90         {TARGET_FILE2, "<pre>@Deprecated\n" +
    91                  "public&nbsp;void&nbsp;method()</pre>" + NL +
    91                  "public&nbsp;void&nbsp;method()</pre>\n" +
    92                  "<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"},
    92                  "<div class=\"block\"><span class=\"deprecatedLabel\">Deprecated.</span>&nbsp;</div>"},
    93     };
    93     };
    94 
    94 
    95     private static final String[][] NEGATED_TEST = NO_TEST;
    95     private static final String[][] NEGATED_TEST = NO_TEST;
    96 
    96