langtools/test/com/sun/javadoc/testProfiles/TestProfiles.java
author akulyakh
Thu, 21 May 2015 11:41:04 -0700
changeset 30730 d3ce7619db2c
parent 29957 7740f9657f56
permissions -rw-r--r--
8076543: Add @modules as needed to the langtools tests Reviewed-by: jjg, shurailine
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     1
/*
29429
964498d4dcec 8074521: Generate iframe instead of frame and frameset for index.html page
bpatel
parents: 24399
diff changeset
     2
 * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved.
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     4
 *
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     7
 * published by the Free Software Foundation.
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     8
 *
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    13
 * accompanied this code).
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    14
 *
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    18
 *
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    21
 * questions.
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    22
 */
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    23
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    24
/*
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    25
 * @test
21494
eb34dbccfb60 8026770: javadoc creates invalid HTML in profile summary pages
bpatel
parents: 21478
diff changeset
    26
 * @bug      8006124 8009684 8016921 8023700 8024096 8008164 8026567 8026770
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    27
 * @summary  Test javadoc support for profiles.
19913
2adc7be8a60b 8015663: Need to supply tests to provide javadoc for profiles support code coverage
jjg
parents: 19907
diff changeset
    28
 * @author   Bhavesh Patel, Evgeniya Stepanova
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    29
 * @library ../lib
30730
d3ce7619db2c 8076543: Add @modules as needed to the langtools tests
akulyakh
parents: 29957
diff changeset
    30
 * @modules jdk.javadoc
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    31
 * @build    JavadocTester
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    32
 * @run main TestProfiles
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    33
 */
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    34
public class TestProfiles extends JavadocTester {
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    35
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    36
    public static void main(String... args) throws Exception {
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    37
        TestProfiles tester = new TestProfiles();
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    38
        tester.runTests();
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    39
    }
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    40
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    41
    @Test
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    42
    void testProfiles() {
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    43
        javadoc("-d", "out-profiles",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    44
                "-sourcepath", testSrc,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    45
                "-Xprofilespath", testSrc("profile-rtjar-includes.txt"),
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    46
                "pkg1", "pkg2", "pkg3", "pkg4", "pkg5", "pkgDeprecated");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    47
        checkExit(Exit.OK);
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    48
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    49
        // Tests for profile-overview-frame.html listing all profiles.
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    50
        checkOutput("profile-overview-frame.html", true,
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
    51
                "<li><a href=\"overview-frame.html\" "
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
    52
                + "target=\"packageListFrame\">All&nbsp;Packages</a></li>",
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    53
                "<li><a href=\"compact1-frame.html\" target=\"packageListFrame\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    54
                + "compact1</a></li>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    55
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    56
        // Tests for profileName-frame.html listing all packages in a profile.
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    57
        checkOutput("compact2-frame.html", true,
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
    58
                "<li><a href=\"overview-frame.html\" target=\"packageListFrame\">"
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
    59
                + "All&nbsp;Packages</a></li>\n<li><a href=\"profile-overview-frame.html\" "
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
    60
                + "target=\"packageListFrame\">All&nbsp;Profiles</a></li>",
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    61
                "<li><a href=\"pkg4/compact2-package-frame.html\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    62
                + "target=\"packageFrame\">pkg4</a></li>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    63
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    64
        // Test for profileName-package-frame.html listing all types in a
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    65
        // package of a profile.
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    66
        checkOutput("pkg2/compact2-package-frame.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    67
                "<a href=\"../compact2-summary.html\" target=\"classFrame\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    68
                + "compact2</a> - <a href=\"../pkg2/compact2-package-summary.html\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    69
                + "target=\"classFrame\">pkg2</a>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    70
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    71
        // Tests for profileName-summary.html listing the summary for a profile.
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    72
        checkOutput("compact2-summary.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    73
                "<li><a href=\"compact1-summary.html\">Prev&nbsp;Profile</a></li>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    74
                + "<li><a href=\"compact3-summary.html\">Next&nbsp;Profile</a></li>",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    75
                "<h1 title=\"Profile\" class=\"title\">Profile&nbsp;compact2</h1>",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    76
                "<h3><a href=\"pkg2/compact2-package-summary.html\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    77
                + "target=\"classFrame\">pkg2</a></h3>",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    78
                "<ul class=\"blockList\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    79
                + "<li class=\"blockList\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    80
                + "<h3><a href=\"pkg2/compact2-package-summary.html\" target=\"classFrame\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    81
                + "pkg2</a></h3>\n"
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
    82
                + "<table class=\"typeSummary\" summary=\"Class Summary table, "
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    83
                + "listing classes, and an explanation\">",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    84
                "<ul class=\"blockList\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    85
                + "<li class=\"blockList\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    86
                + "<h3><a href=\"pkg4/compact2-package-summary.html\" target=\"classFrame\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    87
                + "pkg4</a></h3>\n"
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
    88
                + "<table class=\"typeSummary\" summary=\"Class Summary table, "
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    89
                + "listing classes, and an explanation\">");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    90
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    91
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    92
        // Tests for profileName-package-summary.html listing the summary for a
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
    93
        // package in a profile.
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    94
        checkOutput("pkg5/compact3-package-summary.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    95
                "<li><a href=\"../pkg4/compact3-package-summary.html\">Prev&nbsp;Package"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    96
                + "</a></li>",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    97
                "<div class=\"subTitle\">compact3</div>",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    98
                "<ul class=\"blockList\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
    99
                + "<li class=\"blockList\">\n"
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
   100
                + "<table class=\"typeSummary\" summary=\"Interface Summary table, listing "
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   101
                + "interfaces, and an explanation\">");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   102
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   103
        // Test for "overview-frame.html" showing the "All Profiles" link.
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   104
        checkOutput("overview-frame.html", true,
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
   105
                "<li><a href=\"profile-overview-frame.html\" "
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
   106
                + "target=\"packageListFrame\">All&nbsp;Profiles</a></li>");
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   107
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   108
        // Test for "className.html" showing the profile information for the type.
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   109
        checkOutput("pkg2/Class1Pkg2.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   110
                "<div class=\"subTitle\">compact1, compact2, compact3</div>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   111
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   112
        checkOutput("index.html", true,
29429
964498d4dcec 8074521: Generate iframe instead of frame and frameset for index.html page
bpatel
parents: 24399
diff changeset
   113
                "<iframe src=\"overview-frame.html\" name=\"packageListFrame\" "
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   114
                + "title=\"All Packages\">");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   115
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   116
        // Test for "overview-summary.html" showing the profile list.
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   117
        checkOutput("overview-summary.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   118
                "<ul>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   119
                + "<li><a href=\"compact1-summary.html\" target=\"classFrame\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   120
                + "compact1</a></li>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   121
                + "<li><a href=\"compact2-summary.html\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   122
                + "target=\"classFrame\">compact2</a></li>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   123
                + "<li><a href=\""
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   124
                + "compact3-summary.html\" target=\"classFrame\">compact3</a></li>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   125
                + "</ul>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   126
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   127
        // Test deprecated class in profiles
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   128
        checkOutput("compact1-summary.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   129
                "<td class=\"colFirst\"><a href=\"pkg2/Class1Pkg2.html\" title=\"class in pkg2\">Class1Pkg2</a></td>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   130
                + "<td class=\"colLast\">Deprecated");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   131
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   132
        checkOutput("deprecated-list.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   133
                "<td class=\"colOne\"><a href=\"pkg2/Class1Pkg2.html\" title=\"class in pkg2\">pkg2.Class1Pkg2</a>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   134
                + "<div class=\"block\"><span class=\"deprecationComment\">Class1Pkg2. This class is deprecated</span></div>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   135
19913
2adc7be8a60b 8015663: Need to supply tests to provide javadoc for profiles support code coverage
jjg
parents: 19907
diff changeset
   136
        //Test deprecated package in profile
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   137
        checkOutput("deprecated-list.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   138
                "<td class=\"colOne\"><a href=\"pkgDeprecated/package-summary.html\">pkgDeprecated</a>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   139
                + "<div class=\"block\"><span class=\"deprecationComment\">This package is <b>Deprecated</b>."
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   140
                + " Use pkg1.</span></div>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   141
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   142
        checkOutput("pkgDeprecated/package-summary.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   143
                "<div class=\"deprecatedContent\"><span class=\"deprecatedLabel\">Deprecated.</span>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   144
                + "<div class=\"block\"><span class=\"deprecationComment\">This package is <b>Deprecated</b>."
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   145
                + " Use pkg1.</span></div>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   146
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   147
        // TODO: need to add teststring when JDK-8015496 will be fixed
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   148
        // Test exception in profiles
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   149
        checkOutput("compact1-summary.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   150
                "<table class=\"typeSummary\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   151
                + "summary=\"Exception Summary table, listing exceptions, and an explanation\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   152
                + "<caption><span>Exception Summary</span><span class=\"tabEnd\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   153
                + "&nbsp;</span></caption>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   154
                + "<tr>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   155
                + "<th class=\"colFirst\" scope=\"col\">Exception</th>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   156
                + "<th class=\"colLast\" scope=\"col\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   157
                + "Description</th>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   158
                + "</tr>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   159
                + "<tbody>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   160
                + "<tr class=\"altColor\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   161
                + "<td class=\"colFirst\"><a href=\"pkg2/ClassException.html\""
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   162
                + " title=\"class in pkg2\">ClassException</a></td>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   163
19913
2adc7be8a60b 8015663: Need to supply tests to provide javadoc for profiles support code coverage
jjg
parents: 19907
diff changeset
   164
        //Test errors in profiles
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   165
        checkOutput("compact1-summary.html", true,
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
   166
                "<table class=\"typeSummary\" summary=\"Error Summary table, listing errors, and an explanation\">\n"
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   167
                + "<caption><span>Error Summary</span><span class=\"tabEnd\">&nbsp;"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   168
                + "</span></caption>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   169
                + "<tr>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   170
                + "<th class=\"colFirst\" scope=\"col\">Error</th>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   171
                + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   172
                + "</tr>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   173
                + "<tbody>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   174
                + "<tr class=\"altColor\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   175
                + "<td class=\"colFirst\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   176
                + "<a href=\"pkg2/ClassError.html\" title=\"class in pkg2\">ClassError</a></td>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   177
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   178
        // negative tests
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   179
        checkOutput("pkg3/Class2Pkg3.html", false,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   180
            "<div class=\"subTitle\">compact1");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   181
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   182
        checkOutput("pkg3/Interface1Pkg3.html", false,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   183
            "<div class=\"subTitle\">compact1");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   184
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   185
        checkOutput("pkg4/compact2-package-frame.html", false,
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
   186
            "<li><a href=\"Anno1Pkg4.html\" title=\"annotation in pkg4\" "
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   187
            + "target=\"classFrame\">Anno1Pkg4</a></li>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   188
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   189
        checkOutput("compact1-summary.html", false,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   190
                "<li>Use</li>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   191
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   192
        checkOutput("compact2-summary.html", false,
23971
f5ff1f5a8dee 8031649: Clean up javadoc tests
jjg
parents: 21494
diff changeset
   193
            "<ul class=\"blockList\">\n" +
f5ff1f5a8dee 8031649: Clean up javadoc tests
jjg
parents: 21494
diff changeset
   194
            "<li class=\"blockList\">\n"
21494
eb34dbccfb60 8026770: javadoc creates invalid HTML in profile summary pages
bpatel
parents: 21478
diff changeset
   195
            + "<h3><a href=\"pkg2/compact2-package-summary.html\" target=\"classFrame\">"
23971
f5ff1f5a8dee 8031649: Clean up javadoc tests
jjg
parents: 21494
diff changeset
   196
            + "pkg2</a></h3>\n" +
f5ff1f5a8dee 8031649: Clean up javadoc tests
jjg
parents: 21494
diff changeset
   197
            "<li class=\"blockList\">\n"
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
   198
            + "<table class=\"typeSummary\" summary=\"Class Summary table, "
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   199
            + "listing classes, and an explanation\">");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   200
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   201
        checkOutput("pkg5/compact3-package-summary.html", false,
23971
f5ff1f5a8dee 8031649: Clean up javadoc tests
jjg
parents: 21494
diff changeset
   202
            "<ul class=\"blockList\">\n" +
f5ff1f5a8dee 8031649: Clean up javadoc tests
jjg
parents: 21494
diff changeset
   203
            "<li class=\"blockList\">\n"
f5ff1f5a8dee 8031649: Clean up javadoc tests
jjg
parents: 21494
diff changeset
   204
            + "<li class=\"blockList\">\n"
29957
7740f9657f56 8072945: Javadoc should generate valid and compliant HTML5 output
bpatel
parents: 29429
diff changeset
   205
            + "<table class=\"typeSummary\" summary=\"Interface Summary table, listing "
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   206
            + "interfaces, and an explanation\">");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   207
    }
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   208
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   209
    @Test
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   210
    void testPackages() {
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   211
        javadoc("-d", "out-packages",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   212
                "-sourcepath", testSrc,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   213
                "pkg1", "pkg2", "pkg3", "pkg4", "pkg5");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   214
        checkExit(Exit.OK);
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   215
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   216
        checkOutput("overview-frame.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   217
                "<h2 title=\"Packages\">Packages</h2>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   218
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   219
        checkOutput("pkg4/package-frame.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   220
                "<h1 class=\"bar\"><a href=\"../pkg4/package-summary.html\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   221
                + "target=\"classFrame\">pkg4</a></h1>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   222
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   223
        checkOutput("pkg4/package-summary.html", true,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   224
                "<div class=\"header\">\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   225
                + "<h1 title=\"Package\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   226
                + "class=\"title\">Package&nbsp;pkg4</h1>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   227
                + "</div>");
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
   228
24399
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   229
        checkOutput("overview-frame.html", false,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   230
                "<span><a href=\"profile-overview-frame.html\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   231
                + "target=\"packageListFrame\">All&nbsp;Profiles</a></span>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   232
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   233
        checkOutput("pkg2/Class1Pkg2.html", false,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   234
                "<div class=\"subTitle\">compact1, compact2, compact3</div>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   235
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   236
        checkOutput("overview-summary.html", false,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   237
                "<ul>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   238
                + "<li><a href=\"compact1-summary.html\" target=\"classFrame\">"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   239
                + "compact1</a></li>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   240
                + "<li><a href=\"compact2-summary.html\" "
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   241
                + "target=\"classFrame\">compact2</a></li>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   242
                + "<li><a href=\""
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   243
                + "compact3-summary.html\" target=\"classFrame\">compact3</a></li>\n"
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   244
                + "</ul>");
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   245
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   246
        checkFiles(false,
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   247
                "profile-overview-frame.html",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   248
                "compact2-frame.html",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   249
                "pkg2/compact2-package-frame.html",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   250
                "compact2-summary.html",
af1a0220d0fa 8038730: Clean up the way JavadocTester is invoked, and checks for errors.
jjg
parents: 24072
diff changeset
   251
                "pkg5/compact3-package-summary.html");
15723
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
   252
    }
58a73dac9ee4 8006124: javadoc/doclet should be updated to support profiles
bpatel
parents:
diff changeset
   253
}