1 /*
   2  * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   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
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 /*
  25  * @test
  26  * @bug 8154119 8154262 8156077 8157987 8154261 8154817 8135291 8155995 8162363
  27  *      8168766 8168688 8162674 8160196 8175799 8174974 8176778 8177562 8175218
  28  *      8175823 8166306 8178043 8181622 8183511 8169819 8074407 8183037 8191464
  29         8164407 8192007
  30  * @summary Test modules support in javadoc.
  31  * @author bpatel
  32  * @library ../lib
  33  * @modules jdk.javadoc/jdk.javadoc.internal.tool
  34  * @build JavadocTester
  35  * @run main TestModules
  36  */
  37 public class TestModules extends JavadocTester {
  38 
  39     public static void main(String... args) throws Exception {
  40         TestModules tester = new TestModules();
  41         tester.runTests();
  42     }
  43 
  44     /**
  45      * Test generated module pages for HTML 4.
  46      */
  47     @Test
  48     void testHtml4() {
  49         javadoc("-d", "out", "-use", "-Xdoclint:none",
  50                 "-overview", testSrc("overview.html"),
  51                 "--module-source-path", testSrc,
  52                 "--module", "moduleA,moduleB",
  53                 "testpkgmdlA", "testpkgmdlB");
  54         checkExit(Exit.OK);
  55         checkDescription(true);
  56         checkNoDescription(false);
  57         checkOverviewSummaryModules();
  58         checkModuleLink();
  59         checkModuleClickThroughLinks();
  60         checkModuleClickThrough(true);
  61         checkModuleFilesAndLinks(true);
  62         checkModulesInSearch(true);
  63         checkOverviewFrame(true);
  64     }
  65 
  66     /**
  67      * Test generated module pages for HTML 5.
  68      */
  69     @Test
  70     void testHtml5() {
  71         javadoc("-d", "out-html5", "-html5", "-use", "-Xdoclint:none",
  72                 "-overview", testSrc("overview.html"),
  73                 "--module-source-path", testSrc,
  74                 "--module", "moduleA,moduleB",
  75                 "testpkgmdlA", "testpkgmdlB");
  76         checkExit(Exit.OK);
  77         checkHtml5Description(true);
  78         checkHtml5NoDescription(false);
  79         checkHtml5OverviewSummaryModules();
  80         checkModuleLink();
  81         checkModuleClickThroughLinks();
  82         checkModuleClickThrough(true);
  83         checkModuleFilesAndLinks(true);
  84         checkModulesInSearch(true);
  85         checkOverviewFrame(true);
  86     }
  87 
  88     /**
  89      * Test generated module pages for HTML 4 with -nocomment option.
  90      */
  91     @Test
  92     void testHtml4NoComment() {
  93         javadoc("-d", "out-nocomment", "-nocomment", "-use", "-Xdoclint:none",
  94                 "-overview", testSrc("overview.html"),
  95                 "--module-source-path", testSrc,
  96                 "--module", "moduleA,moduleB",
  97                 "testpkgmdlA", "testpkgmdlB");
  98         checkExit(Exit.OK);
  99         checkDescription(false);
 100         checkNoDescription(true);
 101         checkModuleLink();
 102         checkModuleFilesAndLinks(true);
 103         checkOverviewFrame(true);
 104     }
 105 
 106     /**
 107      * Test generated module pages for HTML 5 with -nocomment option.
 108      */
 109     @Test
 110     void testHtml5NoComment() {
 111         javadoc("-d", "out-html5-nocomment", "-nocomment", "-html5", "-use", "-Xdoclint:none",
 112                 "-overview", testSrc("overview.html"),
 113                 "--module-source-path", testSrc,
 114                 "--module", "moduleA,moduleB",
 115                 "testpkgmdlA", "testpkgmdlB");
 116         checkExit(Exit.OK);
 117         checkHtml5Description(false);
 118         checkHtml5NoDescription(true);
 119         checkModuleLink();
 120         checkModuleFilesAndLinks(true);
 121         checkOverviewFrame(true);
 122     }
 123 
 124     /**
 125      * Test generated pages, in an unnamed module, for HTML 4.
 126      */
 127     @Test
 128     void testHtml4UnnamedModule() {
 129         javadoc("-d", "out-nomodule", "-use",
 130                 "-overview", testSrc("overview.html"),
 131                 "-sourcepath", testSrc,
 132                 "testpkgnomodule", "testpkgnomodule1");
 133         checkExit(Exit.OK);
 134         checkOverviewSummaryPackages();
 135         checkModuleClickThrough(false);
 136         checkModuleFilesAndLinks(false);
 137         checkModulesInSearch(false);
 138         checkOverviewFrame(false);
 139     }
 140 
 141     /**
 142      * Test generated pages, in an unnamed module, for HTML 5.
 143      */
 144     @Test
 145     void testHtml5UnnamedModule() {
 146         javadoc("-d", "out-html5-nomodule", "-html5", "-use",
 147                 "-overview", testSrc("overview.html"),
 148                 "-sourcepath", testSrc,
 149                 "testpkgnomodule", "testpkgnomodule1");
 150         checkExit(Exit.OK);
 151         checkHtml5OverviewSummaryPackages();
 152         checkModuleFilesAndLinks(false);
 153         checkModulesInSearch(false);
 154         checkOverviewFrame(false);
 155     }
 156 
 157     /**
 158      * Test generated module pages with javadoc tags.
 159      */
 160     @Test
 161     void testJDTagsInModules() {
 162         javadoc("-d", "out-mdltags", "-author", "-version", "-Xdoclint:none",
 163                 "-tag", "regular:a:Regular Tag:",
 164                 "-tag", "moduletag:s:Module Tag:",
 165                 "--module-source-path", testSrc,
 166                 "--module", "moduletags,moduleB",
 167                 "testpkgmdltags", "testpkgmdlB");
 168         checkExit(Exit.OK);
 169         checkModuleTags();
 170     }
 171 
 172     /**
 173      * Test generated module summary page.
 174      */
 175     @Test
 176     void testModuleSummary() {
 177         javadoc("-d", "out-moduleSummary", "-use", "-Xdoclint:none",
 178                 "--module-source-path", testSrc,
 179                 "--module", "moduleA,moduleB",
 180                 "testpkgmdlA", "testpkgmdlB", "moduleB/testpkg2mdlB");
 181         checkExit(Exit.OK);
 182         checkModuleSummary();
 183         checkNegatedModuleSummary();
 184     }
 185 
 186     /**
 187      * Test generated module summary page of an aggregating module.
 188      */
 189     @Test
 190     void testAggregatorModuleSummary() {
 191         javadoc("-d", "out-aggregatorModuleSummary", "-use",
 192                 "--module-source-path", testSrc,
 193                 "--expand-requires", "transitive",
 194                 "--module", "moduleT");
 195         checkExit(Exit.OK);
 196         checkAggregatorModuleSummary();
 197     }
 198 
 199     /**
 200      * Test generated module pages and pages with link to modules.
 201      */
 202     @Test
 203     void testModuleFilesAndLinks() {
 204         javadoc("-d", "out-modulelinks", "-Xdoclint:none",
 205                 "--module-source-path", testSrc,
 206                 "--module", "moduleA,moduleB",
 207                 "testpkgmdlA", "testpkgmdlB");
 208         checkExit(Exit.OK);
 209         checkModuleFilesAndLinks(true);
 210         checkOverviewFrame(true);
 211     }
 212 
 213     /**
 214      * Test generated module pages for a deprecated module.
 215      */
 216     @Test
 217     void testModuleDeprecation() {
 218         javadoc("-d", "out-moduledepr", "-Xdoclint:none",
 219                 "-tag", "regular:a:Regular Tag:",
 220                 "-tag", "moduletag:s:Module Tag:",
 221                 "--module-source-path", testSrc,
 222                 "--module", "moduleA,moduleB,moduletags",
 223                 "testpkgmdlA", "testpkgmdlB", "testpkgmdltags");
 224         checkExit(Exit.OK);
 225         checkModuleDeprecation(true);
 226     }
 227 
 228     /**
 229      * Test annotations on modules.
 230      */
 231     @Test
 232     void testModuleAnnotation() {
 233         javadoc("-d", "out-moduleanno", "-Xdoclint:none",
 234                 "--module-source-path", testSrc,
 235                 "--module", "moduleA,moduleB",
 236                 "testpkgmdlA", "testpkgmdlB");
 237         checkExit(Exit.OK);
 238         checkModuleAnnotation();
 239     }
 240 
 241     /**
 242      * Test module summary pages in "api" mode.
 243      */
 244     @Test
 245     void testApiMode() {
 246         javadoc("-d", "out-api", "-use", "--show-module-contents=api", "-author", "-version", "-Xdoclint:none",
 247                 "-tag", "regular:a:Regular Tag:",
 248                 "-tag", "moduletag:s:Module Tag:",
 249                 "--module-source-path", testSrc,
 250                 "--module", "moduleA,moduleB,moduleC,moduletags",
 251                 "testpkgmdlA", "moduleA/concealedpkgmdlA", "testpkgmdlB", "testpkg2mdlB", "testpkgmdlC", "testpkgmdltags");
 252         checkExit(Exit.OK);
 253         checkModuleModeCommon();
 254         checkModuleModeApi(true);
 255         checkModuleModeAll(false);
 256         checkModuleFrameFiles(true);
 257         checkAllModulesLink(true);
 258     }
 259 
 260     /**
 261      * Test module summary pages in "all" mode.
 262      */
 263     @Test
 264     void testAllMode() {
 265         javadoc("-d", "out-all", "-use", "--show-module-contents=all", "-author", "-version", "-Xdoclint:none",
 266                 "-tag", "regular:a:Regular Tag:",
 267                 "-tag", "moduletag:s:Module Tag:",
 268                 "--module-source-path", testSrc,
 269                 "--module", "moduleA,moduleB,moduleC,moduletags",
 270                 "testpkgmdlA", "moduleA/concealedpkgmdlA", "testpkgmdlB", "testpkg2mdlB", "testpkgmdlC", "testpkgmdltags");
 271         checkExit(Exit.OK);
 272         checkModuleModeCommon();
 273         checkModuleModeApi(false);
 274         checkModuleModeAll(true);
 275         checkModuleFrameFiles(true);
 276         checkAllModulesLink(true);
 277     }
 278 
 279     /**
 280      * Test generated module summary page of a module with no exported package.
 281      */
 282     @Test
 283     void testModuleSummaryNoExportedPkgAll() {
 284         javadoc("-d", "out-ModuleSummaryNoExportedPkgAll", "-use", "--show-module-contents=all",
 285                 "-sourcepath", testSrc + "/moduleNoExport",
 286                 "--module", "moduleNoExport",
 287                 "testpkgmdlNoExport");
 288         checkExit(Exit.OK);
 289         checkModuleSummaryNoExported(true);
 290     }
 291 
 292     /**
 293      * Test generated module summary page of a module with no exported package.
 294      */
 295     @Test
 296     void testModuleSummaryNoExportedPkgApi() {
 297         javadoc("-d", "out-ModuleSummaryNoExportedPkgApi", "-use",
 298                 "-sourcepath", testSrc + "/moduleNoExport",
 299                 "--module", "moduleNoExport",
 300                 "testpkgmdlNoExport");
 301         checkExit(Exit.OK);
 302         checkModuleSummaryNoExported(false);
 303     }
 304 
 305     /**
 306      * Test generated module pages for javadoc run for a single module having a single package.
 307      */
 308     @Test
 309     void testSingleModuleSinglePkg() {
 310         javadoc("-d", "out-singlemod",
 311                 "--module-source-path", testSrc,
 312                 "--module", "moduleC",
 313                 "testpkgmdlC");
 314         checkExit(Exit.OK);
 315         checkModuleFrameFiles(false);
 316     }
 317 
 318     /**
 319      * Test generated module pages for javadoc run for a single module having multiple packages.
 320      */
 321     @Test
 322     void testSingleModuleMultiplePkg() {
 323         javadoc("-d", "out-singlemodmultiplepkg", "--show-module-contents=all", "-Xdoclint:none",
 324                 "--module-source-path", testSrc,
 325                 "--module", "moduleB",
 326                 "testpkg2mdlB", "testpkgmdlB");
 327         checkExit(Exit.OK);
 328         checkAllModulesLink(false);
 329     }
 330 
 331     /**
 332      * Test -group option for modules. The overview-summary.html page should group the modules accordingly.
 333      */
 334     @Test
 335     void testGroupOption() {
 336         javadoc("-d", "out-group", "--show-module-contents=all", "-Xdoclint:none",
 337                 "-tag", "regular:a:Regular Tag:",
 338                 "-tag", "moduletag:s:Module Tag:",
 339                 "--module-source-path", testSrc,
 340                 "-group", "Module Group A", "moduleA*",
 341                 "-group", "Module Group B & C", "moduleB*:moduleC*",
 342                 "-group", "Java SE Modules", "java*",
 343                 "--module", "moduleA,moduleB,moduleC,moduletags",
 344                 "moduleA/concealedpkgmdlA", "testpkgmdlA", "testpkg2mdlB", "testpkgmdlB", "testpkgmdlC",
 345                 "testpkgmdltags");
 346         checkExit(Exit.OK);
 347         checkGroupOption();
 348     }
 349 
 350     /**
 351      * Test -group option for modules and the ordering of module groups.
 352      * The overview-summary.html page should group the modules accordingly and display the group tabs in
 353      * the order it was provided on the command-line.
 354      */
 355     @Test
 356     void testGroupOptionOrdering() {
 357         javadoc("-d", "out-groupOrder", "--show-module-contents=all", "-Xdoclint:none",
 358                 "-tag", "regular:a:Regular Tag:",
 359                 "-tag", "moduletag:s:Module Tag:",
 360                 "--module-source-path", testSrc,
 361                 "-group", "B Group", "moduleB*",
 362                 "-group", "C Group", "moduleC*",
 363                 "-group", "A Group", "moduleA*",
 364                 "-group", "Java SE Modules", "java*",
 365                 "--module", "moduleA,moduleB,moduleC,moduletags",
 366                 "moduleA/concealedpkgmdlA", "testpkgmdlA", "testpkg2mdlB", "testpkgmdlB", "testpkgmdlC",
 367                 "testpkgmdltags");
 368         checkExit(Exit.OK);
 369         checkGroupOptionOrdering();
 370     }
 371 
 372     /**
 373      * Test -group option for unnamed modules. The overview-summary.html page should group the packages accordingly.
 374      */
 375     @Test
 376     void testUnnamedModuleGroupOption() {
 377         javadoc("-d", "out-groupnomodule", "-use", "-Xdoclint:none",
 378                 "-overview", testSrc("overview.html"),
 379                 "-sourcepath", testSrc,
 380                 "-group", "Package Group 0", "testpkgnomodule",
 381                 "-group", "Package Group 1", "testpkgnomodule1",
 382                 "testpkgnomodule", "testpkgnomodule1");
 383         checkExit(Exit.OK);
 384         checkUnnamedModuleGroupOption();
 385     }
 386 
 387     /**
 388      * Test -group option for unnamed modules and the ordering of package groups.
 389      * The overview-summary.html page should group the packages accordingly and display the group tabs in
 390      * the order it was provided on the command-line.
 391      */
 392     @Test
 393     void testGroupOptionPackageOrdering() {
 394         javadoc("-d", "out-groupPkgOrder", "-use", "-Xdoclint:none",
 395                 "-overview", testSrc("overview.html"),
 396                 "-sourcepath", testSrc,
 397                 "-group", "Z Group", "testpkgnomodule",
 398                 "-group", "A Group", "testpkgnomodule1",
 399                 "testpkgnomodule", "testpkgnomodule1");
 400         checkExit(Exit.OK);
 401         checkGroupOptionPackageOrdering();
 402     }
 403 
 404     /**
 405      * Test -group option for a single module.
 406      */
 407     @Test
 408     void testGroupOptionSingleModule() {
 409         javadoc("-d", "out-groupsinglemodule", "-use", "-Xdoclint:none",
 410                 "--module-source-path", testSrc,
 411                 "-group", "Module Group B", "moduleB*",
 412                 "--module", "moduleB",
 413                 "testpkg2mdlB", "testpkgmdlB");
 414         checkExit(Exit.OK);
 415         checkGroupOptionSingleModule();
 416     }
 417 
 418     /**
 419      * Test -group option for a single module.
 420      */
 421     @Test
 422     void testModuleName() {
 423         javadoc("-d", "out-modulename", "-use", "-Xdoclint:none",
 424                 "--module-source-path", testSrc,
 425                 "--module", "moduleB,test.moduleFullName",
 426                 "testpkg2mdlB", "testpkgmdlB", "testpkgmdlfullname");
 427         checkExit(Exit.OK);
 428         checkModuleName(true);
 429     }
 430 
 431     /**
 432      * Test -linkoffline option.
 433      */
 434     @Test
 435     void testLinkOffline() {
 436         String url = "https://docs.oracle.com/javase/9/docs/api/";
 437         javadoc("-d", "out-linkoffline", "-use", "--show-module-contents=all", "-Xdoclint:none",
 438                 "--module-source-path", testSrc,
 439                 "--module", "moduleA,moduleB",
 440                 "-linkoffline", url, testSrc + "/jdk",
 441                 "testpkgmdlA", "testpkgmdlB", "testpkg3mdlB");
 442         checkExit(Exit.OK);
 443         checkLinkOffline();
 444     }
 445 
 446     void checkDescription(boolean found) {
 447         checkOutput("moduleA/module-summary.html", found,
 448                 "<!-- ============ MODULE DESCRIPTION =========== -->\n"
 449                 + "<a name=\"module.description\">\n"
 450                 + "<!--   -->\n"
 451                 + "</a>\n"
 452                 + "<div class=\"block\">This is a test description for the moduleA module with a Search "
 453                 + "phrase <a id=\"searchphrase\" class=\"searchTagResult\">search phrase</a>.</div>");
 454         checkOutput("moduleB/module-summary.html", found,
 455                 "<!-- ============ MODULE DESCRIPTION =========== -->\n"
 456                 + "<a name=\"module.description\">\n"
 457                 + "<!--   -->\n"
 458                 + "</a>\n"
 459                 + "<div class=\"block\">This is a test description for the moduleB module. Search "
 460                 + "word <a id=\"search_word\" class=\"searchTagResult\">search_word</a> with no description.</div>");
 461         checkOutput("overview-summary.html", found,
 462                 "</script>\n"
 463                 + "<div class=\"contentContainer\">\n"
 464                 + "<div class=\"block\">The overview summary page header.</div>\n"
 465                 + "</div>\n"
 466                 + "<div class=\"contentContainer\">\n"
 467                 + "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
 468                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 469         checkOutput("overview-summary.html", false,
 470                 "</table>\n"
 471                 + "</div>\n"
 472                 + "<div class=\"contentContainer\">\n"
 473                 + "<div class=\"block\">The overview summary page header.</div>\n"
 474                 + "</div>\n"
 475                 + "<div class=\"contentContainer\">\n"
 476                 + "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
 477                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 478     }
 479 
 480     void checkNoDescription(boolean found) {
 481         checkOutput("moduleA/module-summary.html", found,
 482                 "<div class=\"contentContainer\">\n"
 483                 + "<ul class=\"blockList\">\n"
 484                 + "<li class=\"blockList\">\n"
 485                 + "<ul class=\"blockList\">\n"
 486                 + "<li class=\"blockList\">\n"
 487                 + "<!-- ============ PACKAGES SUMMARY =========== -->");
 488         checkOutput("moduleB/module-summary.html", found,
 489                 "<div class=\"contentContainer\">\n"
 490                 + "<ul class=\"blockList\">\n"
 491                 + "<li class=\"blockList\">\n"
 492                 + "<ul class=\"blockList\">\n"
 493                 + "<li class=\"blockList\">\n"
 494                 + "<!-- ============ PACKAGES SUMMARY =========== -->");
 495     }
 496 
 497     void checkHtml5Description(boolean found) {
 498         checkOutput("moduleA/module-summary.html", found,
 499                 "<section role=\"region\">\n"
 500                 + "<div class=\"deprecationBlock\"><span class=\"deprecatedLabel\">Deprecated, for removal:"
 501                 + " This API element is subject to removal in a future version.</span>\n"
 502                 + "<div class=\"deprecationComment\">This module is deprecated.</div>\n"
 503                 + "</div>\n"
 504                 + "<!-- ============ MODULE DESCRIPTION =========== -->\n"
 505                 + "<a id=\"module.description\">\n"
 506                 + "<!--   -->\n"
 507                 + "</a>\n"
 508                 + "<div class=\"block\">This is a test description for the moduleA module with a Search "
 509                 + "phrase <a id=\"searchphrase\" class=\"searchTagResult\">search phrase</a>.</div>");
 510         checkOutput("moduleB/module-summary.html", found,
 511                 "<section role=\"region\">\n"
 512                 + "<!-- ============ MODULE DESCRIPTION =========== -->\n"
 513                 + "<a id=\"module.description\">\n"
 514                 + "<!--   -->\n"
 515                 + "</a>\n"
 516                 + "<div class=\"block\">This is a test description for the moduleB module. Search "
 517                 + "word <a id=\"search_word\" class=\"searchTagResult\">search_word</a> with no description.</div>");
 518         checkOutput("overview-summary.html", found,
 519                 "</nav>\n"
 520                 + "</header>\n"
 521                 + "<main role=\"main\">\n"
 522                 + "<div class=\"contentContainer\">\n"
 523                 + "<div class=\"block\">The overview summary page header.</div>\n"
 524                 + "</div>\n"
 525                 + "<div class=\"contentContainer\">\n"
 526                 + "<table class=\"overviewSummary\">\n"
 527                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 528         checkOutput("overview-summary.html", false,
 529                 "</table>\n"
 530                 + "</div>\n"
 531                 + "</main>\n"
 532                 + "<main role=\"main\">\n"
 533                 + "<div class=\"contentContainer\">\n"
 534                 + "<div class=\"block\">The overview summary page header.</div>\n"
 535                 + "</div>\n"
 536                 + "<div class=\"contentContainer\">\n"
 537                 + "<table class=\"overviewSummary\">\n"
 538                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 539     }
 540 
 541     void checkHtml5NoDescription(boolean found) {
 542         checkOutput("moduleA/module-summary.html", found,
 543                 "<div class=\"contentContainer\">\n"
 544                 + "<ul class=\"blockList\">\n"
 545                 + "<li class=\"blockList\">\n"
 546                 + "<ul class=\"blockList\">\n"
 547                 + "<li class=\"blockList\">\n"
 548                 + "<!-- ============ PACKAGES SUMMARY =========== -->");
 549         checkOutput("moduleB/module-summary.html", found,
 550                 "<div class=\"contentContainer\">\n"
 551                 + "<ul class=\"blockList\">\n"
 552                 + "<li class=\"blockList\">\n"
 553                 + "<ul class=\"blockList\">\n"
 554                 + "<li class=\"blockList\">\n"
 555                 + "<!-- ============ PACKAGES SUMMARY =========== -->");
 556     }
 557 
 558     void checkModuleLink() {
 559         checkOutput("overview-summary.html", true,
 560                 "<li>Module</li>");
 561         checkOutput("moduleA/module-summary.html", true,
 562                 "<li class=\"navBarCell1Rev\">Module</li>");
 563         checkOutput("moduleB/module-summary.html", true,
 564                 "<li class=\"navBarCell1Rev\">Module</li>");
 565         checkOutput("moduleA/testpkgmdlA/class-use/TestClassInModuleA.html", true,
 566                 "<li><a href=\"../../module-summary.html\">Module</a></li>");
 567         checkOutput("moduleB/testpkgmdlB/package-summary.html", true,
 568                 "<li><a href=\"../module-summary.html\">Module</a></li>");
 569         checkOutput("moduleB/testpkgmdlB/TestClassInModuleB.html", true,
 570                 "<li><a href=\"../module-summary.html\">Module</a></li>");
 571         checkOutput("moduleB/testpkgmdlB/class-use/TestClassInModuleB.html", true,
 572                 "<li><a href=\"../../module-summary.html\">Module</a></li>");
 573     }
 574 
 575     void checkNoModuleLink() {
 576         checkOutput("testpkgnomodule/package-summary.html", true,
 577                 "<ul class=\"navList\" title=\"Navigation\">\n"
 578                 + "<li><a href=\"../testpkgnomodule/package-summary.html\">Package</a></li>");
 579         checkOutput("testpkgnomodule/TestClassNoModule.html", true,
 580                 "<ul class=\"navList\" title=\"Navigation\">\n"
 581                 + "<li><a href=\"../testpkgnomodule/package-summary.html\">Package</a></li>");
 582         checkOutput("testpkgnomodule/class-use/TestClassNoModule.html", true,
 583                 "<ul class=\"navList\" title=\"Navigation\">\n"
 584                 + "<li><a href=\"../../testpkgnomodule/package-summary.html\">Package</a></li>");
 585     }
 586 
 587     void checkModuleTags() {
 588         checkOutput("moduletags/module-summary.html", true,
 589                 "Type Link: <a href=\"testpkgmdltags/TestClassInModuleTags.html\" title=\"class in "
 590                 + "testpkgmdltags\"><code>TestClassInModuleTags</code></a>.",
 591                 "Member Link: <a href=\"testpkgmdltags/TestClassInModuleTags.html#"
 592                 + "testMethod-java.lang.String-\"><code>testMethod(String)</code></a>.",
 593                 "Package Link: <a href=\"testpkgmdltags/package-summary.html\"><code>testpkgmdltags</code></a>.",
 594                 "<dt><span class=\"simpleTagLabel\">Since:</span></dt>\n"
 595                 + "<dd>JDK 9</dd>",
 596                 "<dt><span class=\"seeLabel\">See Also:</span></dt>\n"
 597                 + "<dd>\"Test see tag\", \n"
 598                 + "<a href=\"testpkgmdltags/TestClassInModuleTags.html\" title=\"class in testpkgmdltags\"><code>"
 599                 + "TestClassInModuleTags</code></a></dd>",
 600                 "<dt><span class=\"simpleTagLabel\">Regular Tag:</span></dt>\n"
 601                 + "<dd>Just a regular simple tag.</dd>",
 602                 "<dt><span class=\"simpleTagLabel\">Module Tag:</span></dt>\n"
 603                 + "<dd>Just a simple module tag.</dd>",
 604                 "<dt><span class=\"simpleTagLabel\">Version:</span></dt>\n"
 605                 + "<dd>1.0</dd>",
 606                 "<dt><span class=\"simpleTagLabel\">Author:</span></dt>\n"
 607                 + "<dd>Bhavesh Patel</dd>");
 608         checkOutput("moduletags/testpkgmdltags/TestClassInModuleTags.html", false,
 609                 "<dt><span class=\"simpleTagLabel\">Module Tag:</span></dt>\n"
 610                 + "<dd>Just a simple module tag.</dd>");
 611     }
 612 
 613     void checkOverviewSummaryModules() {
 614         checkOutput("overview-summary.html", true,
 615                 "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
 616                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 617                 + "<tr>\n"
 618                 + "<th class=\"colFirst\" scope=\"col\">Module</th>\n"
 619                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 620                 + "</tr>");
 621         checkOutput("overview-summary.html", false,
 622                 "<table class=\"overviewSummary\" summary=\"Package Summary table, listing packages, and an explanation\">\n"
 623                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 624                 + "<tr>\n"
 625                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
 626                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 627                 + "</tr>");
 628     }
 629 
 630     void checkOverviewSummaryPackages() {
 631         checkOutput("overview-summary.html", false,
 632                 "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
 633                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 634                 + "<tr>\n"
 635                 + "<th class=\"colFirst\" scope=\"col\">Module</th>\n"
 636                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 637                 + "</tr>",
 638                 "</table>\n"
 639                 + "</div>\n"
 640                 + "<div class=\"contentContainer\">\n"
 641                 + "<div class=\"block\">The overview summary page header.</div>\n"
 642                 + "</div>\n"
 643                 + "<div class=\"contentContainer\">\n"
 644                 + "<table class=\"overviewSummary\" summary=\"Package Summary table, listing packages, and an explanation\">\n"
 645                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 646         checkOutput("overview-summary.html", true,
 647                 "<table class=\"overviewSummary\" summary=\"Package Summary table, listing packages, and an explanation\">\n"
 648                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 649                 + "<tr>\n"
 650                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
 651                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 652                 + "</tr>",
 653                 "</script>\n"
 654                 + "<div class=\"contentContainer\">\n"
 655                 + "<div class=\"block\">The overview summary page header.</div>\n"
 656                 + "</div>\n"
 657                 + "<div class=\"contentContainer\">\n"
 658                 + "<table class=\"overviewSummary\" summary=\"Package Summary table, listing packages, and an explanation\">\n"
 659                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 660     }
 661 
 662     void checkHtml5OverviewSummaryModules() {
 663         checkOutput("overview-summary.html", true,
 664                 "<table class=\"overviewSummary\">\n"
 665                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 666                 + "<tr>\n"
 667                 + "<th class=\"colFirst\" scope=\"col\">Module</th>\n"
 668                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 669                 + "</tr>");
 670         checkOutput("overview-summary.html", false,
 671                 "<table class=\"overviewSummary\">\n"
 672                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 673                 + "<tr>\n"
 674                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
 675                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 676                 + "</tr>");
 677     }
 678 
 679     void checkHtml5OverviewSummaryPackages() {
 680         checkOutput("overview-summary.html", false,
 681                 "<table class=\"overviewSummary\">\n"
 682                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 683                 + "<tr>\n"
 684                 + "<th class=\"colFirst\" scope=\"col\">Module</th>\n"
 685                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 686                 + "</tr>",
 687                 "</table>\n"
 688                 + "</div>\n"
 689                 + "</main>\n"
 690                 + "<main role=\"main\">\n"
 691                 + "<div class=\"contentContainer\">\n"
 692                 + "<div class=\"block\">The overview summary page header.</div>\n"
 693                 + "</div>\n"
 694                 + "<div class=\"contentContainer\"><a id=\"Packages\">\n"
 695                 + "<!--   -->\n"
 696                 + "</a>\n"
 697                 + "<table class=\"overviewSummary\">\n"
 698                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 699         checkOutput("overview-summary.html", true,
 700                 "<table class=\"overviewSummary\">\n"
 701                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 702                 + "<tr>\n"
 703                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
 704                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 705                 + "</tr>",
 706                 "</script>\n"
 707                 + "</nav>\n"
 708                 + "</header>\n"
 709                 + "<main role=\"main\">\n"
 710                 + "<div class=\"contentContainer\">\n"
 711                 + "<div class=\"block\">The overview summary page header.</div>\n"
 712                 + "</div>\n"
 713                 + "<div class=\"contentContainer\">\n"
 714                 + "<table class=\"overviewSummary\">\n"
 715                 + "<caption><span>Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>");
 716     }
 717 
 718     void checkModuleSummary() {
 719         checkOutput("moduleA/module-summary.html", true,
 720                 "<ul class=\"subNavList\">\n"
 721                 + "<li>Module:&nbsp;</li>\n"
 722                 + "<li><a href=\"#module.description\">Description</a>&nbsp;|&nbsp;<a "
 723                 + "href=\"#modules.summary\">Modules</a>&nbsp;|&nbsp;<a href=\"#packages.summary\">"
 724                 + "Packages</a>&nbsp;|&nbsp;Services</li>\n"
 725                 + "</ul>",
 726                 "<!-- ============ MODULES SUMMARY =========== -->\n"
 727                 + "<a name=\"modules.summary\">\n"
 728                 + "<!--   -->\n"
 729                 + "</a>",
 730                 "<tr class=\"altColor\" id=\"i0\">\n"
 731                 + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlA/package-summary.html\">testpkgmdlA</a></th>\n"
 732                 + "<td class=\"colLast\">&nbsp;</td>\n"
 733                 + "</tr>",
 734                 "<!-- ============ PACKAGES SUMMARY =========== -->\n"
 735                 + "<a name=\"packages.summary\">\n"
 736                 + "<!--   -->\n"
 737                 + "</a>",
 738                 "<tr class=\"altColor\">\n"
 739                 + "<td class=\"colFirst\">transitive</td>\n"
 740                 + "<th class=\"colSecond\" scope=\"row\"><a href=\"../moduleB/module-summary.html\">moduleB</a></th>\n"
 741                 + "<td class=\"colLast\">\n"
 742                 + "<div class=\"block\">This is a test description for the moduleB module.</div>\n"
 743                 + "</td>\n"
 744                 + "</tr>");
 745         checkOutput("moduleB/module-summary.html", true,
 746                 "<li><a href=\"#module.description\">Description</a>&nbsp;|&nbsp;Modules&nbsp;|&nbsp;"
 747                 + "<a href=\"#packages.summary\">Packages</a>&nbsp;|&nbsp;<a href=\"#services.summary\">"
 748                 + "Services</a></li>",
 749                 "<!-- ============ PACKAGES SUMMARY =========== -->\n"
 750                 + "<a name=\"packages.summary\">\n"
 751                 + "<!--   -->\n"
 752                 + "</a>",
 753                 "<tr class=\"altColor\" id=\"i0\">\n"
 754                 + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlB/package-summary.html\">testpkgmdlB</a></th>\n"
 755                 + "<td class=\"colLast\">&nbsp;</td>\n"
 756                 + "</tr>",
 757                 "<!-- ============ PACKAGES SUMMARY =========== -->\n"
 758                 + "<a name=\"packages.summary\">\n"
 759                 + "<!--   -->\n"
 760                 + "</a>",
 761                 "<!-- ============ SERVICES SUMMARY =========== -->\n"
 762                 + "<a name=\"services.summary\">\n"
 763                 + "<!--   -->\n"
 764                 + "</a>",
 765                 "<tr class=\"altColor\">\n"
 766                 + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlB/TestClassInModuleB.html\" title=\"class in testpkgmdlB\">TestClassInModuleB</a></th>\n"
 767                 + "<td class=\"colLast\">\n"
 768                 + "<div class=\"block\">With a test description for uses.</div>\n</td>\n"
 769                 + "</tr>",
 770                 "<caption><span>Opens</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 771                 + "<tr>\n"
 772                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
 773                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 774                 + "</tr>",
 775                 "<caption><span>Uses</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 776                 + "<tr>\n"
 777                 + "<th class=\"colFirst\" scope=\"col\">Type</th>\n"
 778                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 779                 + "</tr>",
 780                 "<caption><span>Provides</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 781                 + "<tr>\n"
 782                 + "<th class=\"colFirst\" scope=\"col\">Type</th>\n"
 783                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 784                 + "</tr>");
 785     }
 786 
 787     void checkAggregatorModuleSummary() {
 788         checkOutput("moduleT/module-summary.html", true,
 789                 "<div class=\"header\">\n"
 790                 + "<h1 title=\"Module\" class=\"title\">Module&nbsp;moduleT</h1>\n"
 791                 + "</div>",
 792                 "<div class=\"block\">This is a test description for the moduleT module. "
 793                 + "Search phrase <a id=\"searchphrase\" class=\"searchTagResult\">search phrase</a>. "
 794                 + "Make sure there are no exported packages.</div>",
 795                 "<tbody>\n"
 796                 + "<tr class=\"altColor\">\n"
 797                 + "<td class=\"colFirst\">transitive</td>\n"
 798                 + "<th class=\"colSecond\" scope=\"row\"><a href=\"../moduleA/module-summary.html\">moduleA</a></th>\n"
 799                 + "<td class=\"colLast\">\n"
 800                 + "<div class=\"block\">This is a test description for the moduleA module with a Search "
 801                 + "phrase <a id=\"searchphrase\" class=\"searchTagResult\">search phrase</a>.</div>\n"
 802                 + "</td>\n"
 803                 + "</tr>\n"
 804                 + "<tr class=\"rowColor\">\n"
 805                 + "<td class=\"colFirst\">transitive</td>\n"
 806                 + "<th class=\"colSecond\" scope=\"row\"><a href=\"../moduleB/module-summary.html\">moduleB</a></th>\n"
 807                 + "<td class=\"colLast\">\n"
 808                 + "<div class=\"block\">This is a test description for the moduleB module.</div>\n"
 809                 + "</td>\n"
 810                 + "</tr>\n"
 811                 + "</tbody>");
 812     }
 813 
 814     void checkNegatedModuleSummary() {
 815         checkOutput("moduleA/module-summary.html", false,
 816                 "<!-- ============ SERVICES SUMMARY =========== -->\n"
 817                 + "<a name=\"services.summary\">\n"
 818                 + "<!--   -->\n"
 819                 + "</a>");
 820     }
 821 
 822     void checkModuleClickThroughLinks() {
 823         checkOutput("module-overview-frame.html", true,
 824                 "<li><a href=\"moduleA/module-frame.html\" target=\"packageListFrame\" "
 825                 + "onclick=\"updateModuleFrame('moduleA/module-type-frame.html','moduleA/module-summary.html');"
 826                 + "\">moduleA</a></li>",
 827                 "<li><a href=\"moduleB/module-frame.html\" target=\"packageListFrame\" "
 828                 + "onclick=\"updateModuleFrame('moduleB/module-type-frame.html','moduleB/module-summary.html');"
 829                 + "\">moduleB</a></li>");
 830         checkOutput("script.js", true,
 831                 "function updateModuleFrame(pFrame, cFrame)\n"
 832                 + "{\n"
 833                 + "    top.packageFrame.location = pFrame;\n"
 834                 + "    top.classFrame.location = cFrame;\n"
 835                 + "}");
 836     }
 837 
 838     void checkModuleClickThrough(boolean found) {
 839         checkFiles(found,
 840                 "moduleA/module-type-frame.html",
 841                 "moduleB/module-type-frame.html");
 842     }
 843 
 844     void checkModuleFilesAndLinks(boolean found) {
 845         checkFileAndOutput("moduleA/testpkgmdlA/package-summary.html", found,
 846                 "<li><a href=\"../module-summary.html\">Module</a></li>",
 847                 "<div class=\"subTitle\"><span class=\"moduleLabelInPackage\">Module</span>&nbsp;"
 848                 + "<a href=\"../module-summary.html\">moduleA</a></div>");
 849         checkFileAndOutput("moduleA/testpkgmdlA/TestClassInModuleA.html", found,
 850                 "<li><a href=\"../module-summary.html\">Module</a></li>",
 851                 "<div class=\"subTitle\"><span class=\"moduleLabelInType\">Module</span>&nbsp;"
 852                 + "<a href=\"../module-summary.html\">moduleA</a></div>");
 853         checkFileAndOutput("moduleB/testpkgmdlB/AnnotationType.html", found,
 854                 "<div class=\"subTitle\"><span class=\"moduleLabelInType\">Module</span>&nbsp;"
 855                 + "<a href=\"../module-summary.html\">moduleB</a></div>",
 856                 "<div class=\"subTitle\"><span class=\"packageLabelInType\">"
 857                 + "Package</span>&nbsp;<a href=\"package-summary.html\">testpkgmdlB</a></div>");
 858         checkFiles(found,
 859                 "moduleA/module-frame.html",
 860                 "moduleA/module-summary.html",
 861                 "module-overview-frame.html");
 862     }
 863 
 864     void checkModuleFrameFiles(boolean found) {
 865         checkFiles(found,
 866                 "moduleC/module-frame.html",
 867                 "moduleC/module-type-frame.html",
 868                 "module-overview-frame.html");
 869         checkFiles(true,
 870                 "moduleC/module-summary.html",
 871                 "allclasses-frame.html",
 872                 "allclasses-noframe.html");
 873     }
 874 
 875     void checkAllModulesLink(boolean found) {
 876         checkOutput("overview-frame.html", found,
 877                 "<li><a href=\"module-overview-frame.html\" target=\"packageListFrame\">All&nbsp;Modules</a></li>");
 878     }
 879 
 880     void checkModulesInSearch(boolean found) {
 881         checkOutput("index-all.html", found,
 882                 "<dl>\n"
 883                 + "<dt><a href=\"moduleA/module-summary.html\">moduleA</a> - module moduleA</dt>\n"
 884                 + "<dd>\n"
 885                 + "<div class=\"block\">This is a test description for the moduleA module with a Search "
 886                 + "phrase <a id=\"searchphrase\" class=\"searchTagResult\">search phrase</a>.</div>\n"
 887                 + "</dd>\n"
 888                 + "<dt><a href=\"moduleB/module-summary.html\">moduleB</a> - module moduleB</dt>\n"
 889                 + "<dd>\n"
 890                 + "<div class=\"block\">This is a test description for the moduleB module.</div>\n"
 891                 + "</dd>\n"
 892                 + "</dl>",
 893                 "<dl>\n"
 894                 + "<dt><span class=\"searchTagLink\"><a href=\"moduleA/module-summary.html#searchphrase\">"
 895                 + "search phrase</a></span> - Search tag in moduleA</dt>\n"
 896                 + "<dd>with description</dd>\n"
 897                 + "<dt><span class=\"searchTagLink\"><a href=\"moduleB/module-summary.html#search_word\">"
 898                 + "search_word</a></span> - Search tag in moduleB</dt>\n"
 899                 + "<dd>&nbsp;</dd>\n"
 900                 + "</dl>");
 901         checkOutput("index-all.html", false,
 902                 "<dt><span class=\"searchTagLink\"><a href=\"moduleA/module-summary.html#searchphrase\">"
 903                 + "search phrase</a></span> - Search tag in moduleA</dt>\n"
 904                 + "<dd>with description</dd>\n"
 905                 + "<dt><span class=\"searchTagLink\"><a href=\"moduleA/module-summary.html#searchphrase\">"
 906                 + "search phrase</a></span> - Search tag in moduleA</dt>\n"
 907                 + "<dd>with description</dd>");
 908     }
 909 
 910     void checkModuleModeCommon() {
 911         checkOutput("overview-summary.html", true,
 912                 "<th class=\"colFirst\" scope=\"row\"><a href=\"moduleA/module-summary.html\">moduleA</a></th>\n"
 913                 + "<td class=\"colLast\">\n"
 914                 + "<div class=\"block\">This is a test description for the moduleA module with a Search "
 915                 + "phrase <a id=\"searchphrase\" class=\"searchTagResult\">search phrase</a>.</div>\n"
 916                 + "</td>",
 917                 "<th class=\"colFirst\" scope=\"row\"><a href=\"moduleB/module-summary.html\">moduleB</a></th>\n"
 918                 + "<td class=\"colLast\">\n"
 919                 + "<div class=\"block\">This is a test description for the moduleB module.</div>\n"
 920                 + "</td>",
 921                 "<th class=\"colFirst\" scope=\"row\"><a href=\"moduletags/module-summary.html\">moduletags</a></th>\n"
 922                 + "<td class=\"colLast\">\n"
 923                 + "<div class=\"block\">This is a test description for the moduletags module.<br>\n"
 924                 + " Type Link: <a href=\"moduletags/testpkgmdltags/TestClassInModuleTags.html\" title=\"class in testpkgmdltags\"><code>TestClassInModuleTags</code></a>.<br>\n"
 925                 + " Member Link: <a href=\"moduletags/testpkgmdltags/TestClassInModuleTags.html#testMethod-java.lang.String-\"><code>testMethod(String)</code></a>.<br>\n"
 926                 + " Package Link: <a href=\"moduletags/testpkgmdltags/package-summary.html\"><code>testpkgmdltags</code></a>.<br></div>\n"
 927                 + "</td>");
 928         checkOutput("moduleA/module-summary.html", true,
 929                 "<li><a href=\"#module.description\">Description</a>&nbsp;|&nbsp;<a href=\"#modules.summary\">"
 930                 + "Modules</a>&nbsp;|&nbsp;<a href=\"#packages.summary\">Packages</a>&nbsp;|&nbsp;Services</li>",
 931                 "<th class=\"colFirst\" scope=\"row\"><a href=\"../moduleB/module-summary.html\">moduleB</a></th>\n"
 932                 + "<td class=\"colLast\"><a href=\"../moduleB/testpkgmdlB/package-summary.html\">testpkgmdlB</a></td>\n");
 933         checkOutput("moduleB/module-summary.html", true,
 934                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlB/TestClassInModuleB.html\" title=\"class in testpkgmdlB\">TestClassInModuleB</a></th>\n"
 935                 + "<td class=\"colLast\">\n"
 936                 + "<div class=\"block\">With a test description for uses.</div>\n</td>\n");
 937         checkOutput("moduletags/module-summary.html", true,
 938                 "<li><a href=\"#module.description\">Description</a>&nbsp;|&nbsp;<a href=\"#modules.summary\">Modules"
 939                 + "</a>&nbsp;|&nbsp;<a href=\"#packages.summary\">Packages</a>&nbsp;|&nbsp;Services</li>",
 940                 "<table class=\"requiresSummary\" summary=\"Indirect Requires table, listing modules, and an explanation\">\n"
 941                 + "<caption><span>Indirect Requires</span><span class=\"tabEnd\">&nbsp;</span></caption>",
 942                 "<td class=\"colFirst\">transitive</td>\n"
 943                 + "<th class=\"colSecond\" scope=\"row\"><a href=\"../moduleB/module-summary.html\">moduleB</a></th>\n"
 944                 + "<td class=\"colLast\">\n"
 945                 + "<div class=\"block\">This is a test description for the moduleB module.</div>\n"
 946                 + "</td>",
 947                 "<table class=\"packagesSummary\" summary=\"Indirect Exports table, listing modules, and packages\">\n"
 948                 + "<caption><span>Indirect Exports</span><span class=\"tabEnd\">&nbsp;</span></caption>",
 949                 "<td class=\"colFirst\">transitive static</td>\n"
 950                 + "<th class=\"colSecond\" scope=\"row\"><a href=\"../moduleA/module-summary.html\">moduleA</a></th>\n"
 951                 + "<td class=\"colLast\">\n"
 952                 + "<div class=\"block\">This is a test description for the moduleA module with a Search "
 953                 + "phrase <a id=\"searchphrase\" class=\"searchTagResult\">search phrase</a>.</div>\n"
 954                 + "</td>",
 955                 "<table class=\"requiresSummary\" summary=\"Requires table, listing modules, and an explanation\">\n"
 956                 + "<caption><span>Requires</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 957                 + "<tr>\n"
 958                 + "<th class=\"colFirst\" scope=\"col\">Modifier</th>\n"
 959                 + "<th class=\"colSecond\" scope=\"col\">Module</th>\n"
 960                 + "<th class=\"colLast\" scope=\"col\">Description</th>",
 961                 "<table class=\"requiresSummary\" summary=\"Indirect Requires table, listing modules, and an explanation\">\n"
 962                 + "<caption><span>Indirect Requires</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 963                 + "<tr>\n"
 964                 + "<th class=\"colFirst\" scope=\"col\">Modifier</th>\n"
 965                 + "<th class=\"colSecond\" scope=\"col\">Module</th>\n"
 966                 + "<th class=\"colLast\" scope=\"col\">Description</th>",
 967                 "<table class=\"packagesSummary\" summary=\"Indirect Opens table, listing modules, and packages\">\n"
 968                 + "<caption><span>Indirect Opens</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 969                 + "<tr>\n"
 970                 + "<th class=\"colFirst\" scope=\"col\">From</th>\n"
 971                 + "<th class=\"colLast\" scope=\"col\">Packages</th>\n"
 972                 + "</tr>\n",
 973                 "<th class=\"colFirst\" scope=\"row\"><a href=\"../moduleB/module-summary.html\">moduleB</a></th>\n"
 974                 + "<td class=\"colLast\"><a href=\"../moduleB/testpkgmdlB/package-summary.html\">testpkgmdlB</a></td>\n");
 975     }
 976 
 977     void checkModuleModeApi(boolean found) {
 978         checkOutput("moduleA/module-summary.html", found,
 979                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlA/package-summary.html\">testpkgmdlA</a></th>\n"
 980                 + "<td class=\"colLast\">&nbsp;</td>");
 981         checkOutput("moduleB/module-summary.html", found,
 982                 "<li><a href=\"#module.description\">Description</a>&nbsp;|&nbsp;Modules&nbsp;|&nbsp;"
 983                 + "<a href=\"#packages.summary\">Packages</a>&nbsp;|&nbsp;<a href=\"#services.summary\">Services</a></li>",
 984                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlB/package-summary.html\">testpkgmdlB</a></th>\n"
 985                 + "<td class=\"colLast\">&nbsp;</td>",
 986                 "<table class=\"packagesSummary\" summary=\"Packages table, listing packages, and an explanation\">\n"
 987                 + "<caption><span>Opens</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
 988                 + "<tr>\n"
 989                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
 990                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
 991                 + "</tr>\n"
 992                 + "<tbody>\n"
 993                 + "<tr class=\"altColor\" id=\"i0\">\n"
 994                 + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlB/package-summary.html\">testpkgmdlB</a></th>\n"
 995                 + "<td class=\"colLast\">&nbsp;</td>\n"
 996                 + "</tr>\n"
 997                 + "</tbody>\n"
 998                 + "</table>");
 999         checkOutput("moduletags/module-summary.html", true,
1000                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdltags/package-summary.html\">testpkgmdltags</a></th>\n"
1001                 + "<td class=\"colLast\">&nbsp;</td>");
1002     }
1003 
1004     void checkModuleModeAll(boolean found) {
1005         checkOutput("moduleA/module-summary.html", found,
1006                 "<td class=\"colFirst\"> </td>\n"
1007                 + "<th class=\"colSecond\" scope=\"row\">java.base</th>\n"
1008                 + "<td class=\"colLast\">&nbsp;</td>",
1009                 "<td class=\"colFirst\"> </td>\n"
1010                 + "<th class=\"colSecond\" scope=\"row\"><a href=\"../moduleC/module-summary.html\">moduleC</a></th>\n"
1011                 + "<td class=\"colLast\">\n"
1012                 + "<div class=\"block\">This is a test description for the moduleC module.</div>\n"
1013                 + "</td>",
1014                 "<th class=\"colFirst\" scope=\"row\"><a href=\"../moduleC/module-summary.html\">moduleC</a></th>\n"
1015                 + "<td class=\"colLast\"><a href=\"../moduleC/testpkgmdlC/package-summary.html\">testpkgmdlC</a></td>",
1016                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlA/package-summary.html\">testpkgmdlA</a></th>\n"
1017                 + "<td class=\"colSecond\">All Modules</td>\n"
1018                 + "<td class=\"colLast\">&nbsp;</td>",
1019                 "<caption><span id=\"t0\" class=\"activeTableTab\"><span>All Packages</span><span class=\"tabEnd\">&nbsp;</span></span>"
1020                 + "<span id=\"t1\" class=\"tableTab\"><span><a href=\"javascript:showPkgs(1);\">Exports</a></span>"
1021                 + "<span class=\"tabEnd\">&nbsp;</span></span><span id=\"t3\" class=\"tableTab\"><span><a href=\"javascript:showPkgs(4);\">"
1022                 + "Concealed</a></span><span class=\"tabEnd\">&nbsp;</span></span></caption>",
1023                 "<th class=\"colFirst\" scope=\"row\"><a href=\"concealedpkgmdlA/package-summary.html\">concealedpkgmdlA</a></th>\n"
1024                 + "<td class=\"colSecond\">None</td>\n"
1025                 + "<td class=\"colLast\">&nbsp;</td>");
1026         checkOutput("moduleB/module-summary.html", found,
1027                 "<li><a href=\"#module.description\">Description</a>&nbsp;|&nbsp;<a href=\"#modules.summary\">"
1028                 + "Modules</a>&nbsp;|&nbsp;<a href=\"#packages.summary\">Packages</a>&nbsp;|&nbsp;<a href=\"#services.summary\">Services</a></li>",
1029                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlB/package-summary.html\">testpkgmdlB</a></th>\n"
1030                 + "<td class=\"colSecond\">None</td>\n"
1031                 + "<td class=\"colSecond\">All Modules</td>\n"
1032                 + "<td class=\"colLast\">&nbsp;</td>",
1033                 "<td class=\"colFirst\"> </td>\n"
1034                 + "<th class=\"colSecond\" scope=\"row\">java.base</th>\n"
1035                 + "<td class=\"colLast\">&nbsp;</td>",
1036                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdlB/TestClass2InModuleB.html\" title=\"class in testpkgmdlB\">TestClass2InModuleB</a></th>\n"
1037                 + "<td class=\"colLast\">&nbsp;</td>",
1038                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkg2mdlB/TestInterface2InModuleB.html\" title=\"interface in testpkg2mdlB\">TestInterface2InModuleB</a></th>\n"
1039                 + "<td class=\"colLast\">&nbsp;<br>(<span class=\"implementationLabel\">Implementation(s):</span>&nbsp;<a href=\"testpkgmdlB/TestClass2InModuleB.html\" "
1040                 + "title=\"class in testpkgmdlB\">TestClass2InModuleB</a>)</td>",
1041                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkg2mdlB/TestInterfaceInModuleB.html\" title=\"interface in testpkg2mdlB\">TestInterfaceInModuleB</a></th>\n"
1042                 + "<td class=\"colLast\">&nbsp;<br>(<span class=\"implementationLabel\">Implementation(s):</span>&nbsp;<a href=\"testpkgmdlB/TestClassInModuleB.html\" "
1043                 + "title=\"class in testpkgmdlB\">TestClassInModuleB</a>)</td>",
1044                 "<caption><span id=\"t0\" class=\"activeTableTab\"><span>All Packages</span><span class=\"tabEnd\">&nbsp;</span></span><span id=\"t1\" class=\"tableTab\"><span>"
1045                 + "<a href=\"javascript:showPkgs(1);\">Exports</a></span><span class=\"tabEnd\">&nbsp;</span></span><span id=\"t2\" class=\"tableTab\"><span>"
1046                 + "<a href=\"javascript:showPkgs(2);\">Opens</a></span><span class=\"tabEnd\">&nbsp;</span></span></caption>");
1047         checkOutput("moduleC/module-summary.html", found,
1048                 "<caption><span>Exports</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
1049                 + "<tr>\n"
1050                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
1051                 + "<th class=\"colSecond\" scope=\"col\">Exported To Modules</th>\n"
1052                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
1053                 + "</tr>");
1054         checkOutput("moduletags/module-summary.html", true,
1055                 "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdltags/package-summary.html\">testpkgmdltags</a></th>\n"
1056                 + "<td class=\"colLast\">&nbsp;</td>");
1057     }
1058 
1059     void checkModuleDeprecation(boolean found) {
1060         checkOutput("moduleA/module-summary.html", found,
1061                 "<div class=\"deprecationBlock\"><span class=\"deprecatedLabel\">Deprecated, for removal:"
1062                 + " This API element is subject to removal in a future version.</span>\n"
1063                 + "<div class=\"deprecationComment\">This module is deprecated.</div>\n"
1064                 + "</div>");
1065         checkOutput("deprecated-list.html", found,
1066                 "<ul>\n"
1067                 + "<li><a href=\"#forRemoval\">For Removal</a></li>\n"
1068                 + "<li><a href=\"#module\">Modules</a></li>\n"
1069                 + "</ul>",
1070                 "<tr class=\"altColor\">\n"
1071                 + "<th class=\"colDeprecatedItemName\" scope=\"row\"><a href=\"moduleA/module-summary.html\">moduleA</a></th>\n"
1072                 + "<td class=\"colLast\">\n"
1073                 + "<div class=\"deprecationComment\">This module is deprecated.</div>\n"
1074                 + "</td>\n"
1075                 + "</tr>");
1076         checkOutput("moduleB/module-summary.html", !found,
1077                 "<div class=\"deprecationBlock\"><span class=\"deprecatedLabel\">Deprecated.</span>\n"
1078                 + "<div class=\"deprecationComment\">This module is deprecated using just the javadoc tag.</div>\n");
1079         checkOutput("moduletags/module-summary.html", found,
1080                 "<p>@Deprecated\n"
1081                 + "</p>",
1082                 "<div class=\"deprecationBlock\"><span class=\"deprecatedLabel\">Deprecated.</span></div>");
1083     }
1084 
1085     void checkModuleAnnotation() {
1086         checkOutput("moduleB/module-summary.html", true,
1087                 "<p><a href=\"testpkgmdlB/AnnotationType.html\" title=\"annotation in testpkgmdlB\">@AnnotationType</a>(<a href=\"testpkgmdlB/AnnotationType.html#optional--\">optional</a>=\"Module Annotation\",\n"
1088                 + "                <a href=\"testpkgmdlB/AnnotationType.html#required--\">required</a>=2016)\n"
1089                 + "</p>");
1090         checkOutput("moduleB/module-summary.html", false,
1091                 "@AnnotationTypeUndocumented");
1092     }
1093 
1094     void checkOverviewFrame(boolean found) {
1095         checkOutput("index.html", !found,
1096                 "<iframe src=\"overview-frame.html\" name=\"packageListFrame\" title=\"All Packages\"></iframe>");
1097         checkOutput("index.html", found,
1098                 "<iframe src=\"module-overview-frame.html\" name=\"packageListFrame\" title=\"All Modules\"></iframe>");
1099     }
1100 
1101     void checkModuleSummaryNoExported(boolean found) {
1102         checkOutput("moduleNoExport/module-summary.html", found,
1103                 "<!-- ============ PACKAGES SUMMARY =========== -->\n"
1104                 + "<a name=\"packages.summary\">\n"
1105                 + "<!--   -->\n"
1106                 + "</a>",
1107                 "<caption><span>Concealed</span><span class=\"tabEnd\">&nbsp;</span></caption>");
1108     }
1109 
1110     void checkGroupOption() {
1111         checkOutput("overview-summary.html", true,
1112                 "<div class=\"contentContainer\">\n"
1113                 + "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
1114                 + "<caption><span id=\"t0\" class=\"activeTableTab\"><span>All Modules</span><span class=\"tabEnd\">&nbsp;"
1115                 + "</span></span><span id=\"t1\" class=\"tableTab\"><span><a href=\"javascript:showGroups(1);\">"
1116                 + "Module Group A</a></span><span class=\"tabEnd\">&nbsp;</span></span><span id=\"t2\" class=\"tableTab\">"
1117                 + "<span><a href=\"javascript:showGroups(2);\">Module Group B &amp; C</a></span><span class=\"tabEnd\">"
1118                 + "&nbsp;</span></span><span id=\"t4\" class=\"tableTab\"><span><a href=\"javascript:showGroups(4);\">"
1119                 + "Other Modules</a></span><span class=\"tabEnd\">&nbsp;</span></span></caption>",
1120                 "var groups = {\"i0\":1,\"i1\":2,\"i2\":2,\"i3\":4};\n"
1121                 + "var tabs = {65535:[\"t0\",\"All Modules\"],1:[\"t1\",\"Module Group A\"],2:[\"t2\",\"Module Group B & C\"],4:[\"t4\",\"Other Modules\"]};\n"
1122                 + "var altColor = \"altColor\";\n"
1123                 + "var rowColor = \"rowColor\";\n"
1124                 + "var tableTab = \"tableTab\";\n"
1125                 + "var activeTableTab = \"activeTableTab\";");
1126         checkOutput("overview-summary.html", false,
1127                 "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
1128                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>",
1129                 "Java SE Modules");
1130     }
1131 
1132     void checkGroupOptionOrdering() {
1133         checkOutput("overview-summary.html", true,
1134                 "<caption><span id=\"t0\" class=\"activeTableTab\"><span>All Modules</span><span "
1135                 + "class=\"tabEnd\">&nbsp;</span></span><span id=\"t1\" class=\"tableTab\"><span>"
1136                 + "<a href=\"javascript:showGroups(1);\">B Group</a></span><span class=\"tabEnd\">"
1137                 + "&nbsp;</span></span><span id=\"t2\" class=\"tableTab\"><span><a href=\"javascript:showGroups(2);\">"
1138                 + "C Group</a></span><span class=\"tabEnd\">&nbsp;</span></span><span id=\"t4\" class=\"tableTab\">"
1139                 + "<span><a href=\"javascript:showGroups(4);\">A Group</a></span><span class=\"tabEnd\">&nbsp;</span>"
1140                 + "</span><span id=\"t8\" class=\"tableTab\"><span><a href=\"javascript:showGroups(8);\">Other Modules"
1141                 + "</a></span><span class=\"tabEnd\">&nbsp;</span></span></caption>",
1142                 "var tabs = {65535:[\"t0\",\"All Modules\"],1:[\"t1\",\"B Group\"],2:[\"t2\",\"C Group\"],"
1143                 + "4:[\"t4\",\"A Group\"],8:[\"t8\",\"Other Modules\"]};");
1144         checkOutput("overview-summary.html", false,
1145                 "<caption><span id=\"t0\" class=\"activeTableTab\"><span>All Modules</span><span "
1146                 + "class=\"tabEnd\">&nbsp;</span></span><span id=\"t1\" class=\"tableTab\"><span>"
1147                 + "<a href=\"javascript:showGroups(1);\">A Group</a></span><span class=\"tabEnd\">"
1148                 + "&nbsp;</span></span><span id=\"t2\" class=\"tableTab\"><span><a href=\"javascript:showGroups(2);\">"
1149                 + "B Group</a></span><span class=\"tabEnd\">&nbsp;</span></span><span id=\"t4\" class=\"tableTab\">"
1150                 + "<span><a href=\"javascript:showGroups(4);\">C Group</a></span><span class=\"tabEnd\">&nbsp;</span>"
1151                 + "</span><span id=\"t8\" class=\"tableTab\"><span><a href=\"javascript:showGroups(8);\">Other Modules"
1152                 + "</a></span><span class=\"tabEnd\">&nbsp;</span></span></caption>",
1153                 "Java SE Modules");
1154     }
1155 
1156     void checkUnnamedModuleGroupOption() {
1157         checkOutput("overview-summary.html", true,
1158                 "<div class=\"contentContainer\">\n"
1159                 + "<div class=\"block\">The overview summary page header.</div>\n"
1160                 + "</div>\n"
1161                 + "<div class=\"contentContainer\">\n"
1162                 + "<table class=\"overviewSummary\" summary=\"Package Summary table, listing packages, and an explanation\">\n"
1163                 + "<caption><span id=\"t0\" class=\"activeTableTab\"><span>All Packages</span><span class=\"tabEnd\">&nbsp;"
1164                 + "</span></span><span id=\"t1\" class=\"tableTab\"><span><a href=\"javascript:showGroups(1);\">"
1165                 + "Package Group 0</a></span><span class=\"tabEnd\">&nbsp;</span></span><span id=\"t2\" "
1166                 + "class=\"tableTab\"><span><a href=\"javascript:showGroups(2);\">Package Group 1</a></span>"
1167                 + "<span class=\"tabEnd\">&nbsp;</span></span></caption>",
1168                 "var groups = {\"i0\":1,\"i1\":2};\n"
1169                 + "var tabs = {65535:[\"t0\",\"All Packages\"],1:[\"t1\",\"Package Group 0\"],2:[\"t2\",\"Package Group 1\"]};\n"
1170                 + "var altColor = \"altColor\";\n"
1171                 + "var rowColor = \"rowColor\";\n"
1172                 + "var tableTab = \"tableTab\";\n"
1173                 + "var activeTableTab = \"activeTableTab\";");
1174     }
1175 
1176     void checkGroupOptionPackageOrdering() {
1177         checkOutput("overview-summary.html", true,
1178                 "<caption><span id=\"t0\" class=\"activeTableTab\"><span>All Packages</span><span "
1179                 + "class=\"tabEnd\">&nbsp;</span></span><span id=\"t1\" class=\"tableTab\"><span>"
1180                 + "<a href=\"javascript:showGroups(1);\">Z Group</a></span><span class=\"tabEnd\">"
1181                 + "&nbsp;</span></span><span id=\"t2\" class=\"tableTab\"><span><a href=\"javascript:showGroups(2);\">"
1182                 + "A Group</a></span><span class=\"tabEnd\">&nbsp;</span></span></caption>",
1183                 "var tabs = {65535:[\"t0\",\"All Packages\"],1:[\"t1\",\"Z Group\"],2:[\"t2\",\"A Group\"]};");
1184     }
1185 
1186     void checkGroupOptionSingleModule() {
1187         checkOutput("overview-summary.html", true,
1188                 "<div class=\"contentContainer\">\n"
1189                 + "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
1190                 + "<caption><span>Module Group B</span><span class=\"tabEnd\">&nbsp;</span></caption>");
1191         checkOutput("overview-summary.html", false,
1192                 "<table class=\"overviewSummary\" summary=\"Module Summary table, listing modules, and an explanation\">\n"
1193                 + "<caption><span>Modules</span><span class=\"tabEnd\">&nbsp;</span></caption>");
1194     }
1195 
1196     void checkModuleName(boolean found) {
1197         checkOutput("test.moduleFullName/module-summary.html", found,
1198                 "<div class=\"header\">\n"
1199                 + "<h1 title=\"Module\" class=\"title\">Module&nbsp;test.moduleFullName</h1>\n"
1200                 + "</div>");
1201         checkOutput("index-all.html", found,
1202                 "<h2 class=\"title\">T</h2>\n"
1203                 + "<dl>\n"
1204                 + "<dt><a href=\"test.moduleFullName/module-summary.html\">test.moduleFullName</a> - module test.moduleFullName</dt>\n"
1205                 + "<dd>\n"
1206                 + "<div class=\"block\">This is a test description for the test.moduleFullName.</div>\n"
1207                 + "</dd>");
1208         checkOutput("module-overview-frame.html", found,
1209                 "<h2 title=\"Modules\">Modules</h2>\n"
1210                 + "<ul title=\"Modules\">\n"
1211                 + "<li><a href=\"moduleB/module-frame.html\" target=\"packageListFrame\" onclick=\"updateModuleFrame('moduleB/module-type-frame.html','moduleB/module-summary.html');\">moduleB</a></li>\n"
1212                 + "<li><a href=\"test.moduleFullName/module-frame.html\" target=\"packageListFrame\" onclick=\"updateModuleFrame('test.moduleFullName/module-type-frame.html','test.moduleFullName/module-summary.html');\">test.moduleFullName</a></li>\n"
1213                 + "</ul>");
1214         checkOutput("test.moduleFullName/module-summary.html", !found,
1215                 "<div class=\"header\">\n"
1216                 + "<h1 title=\"Module\" class=\"title\">Module&nbsp;moduleFullName</h1>\n"
1217                 + "</div>");
1218         checkOutput("index-all.html", !found,
1219                 "<dl>\n"
1220                 + "<dt><a href=\"test.moduleFullName/module-summary.html\">moduleFullName</a> - module moduleFullName</dt>\n"
1221                 + "<dd>\n"
1222                 + "<div class=\"block\">This is a test description for the test.moduleFullName.</div>\n"
1223                 + "</dd>\n"
1224                 + "</dl>");
1225     }
1226 
1227     void checkLinkOffline() {
1228         checkOutput("moduleB/testpkg3mdlB/package-summary.html", true,
1229                 "<a href=\"https://docs.oracle.com/javase/9/docs/api/java/lang/String.html?is-external=true\" "
1230                 + "title=\"class or interface in java.lang\" class=\"externalLink\"><code>Link to String Class</code></a>");
1231         checkOutput("moduleB/testpkg3mdlB/package-summary.html", true,
1232                 "<a href=\"https://docs.oracle.com/javase/9/docs/api/java/lang/package-summary.html?is-external=true\" "
1233                 + "class=\"externalLink\"><code>Link to java.lang package</code></a>");
1234         checkOutput("moduleB/testpkg3mdlB/package-summary.html", true,
1235                 "<a href=\"https://docs.oracle.com/javase/9/docs/api/java.base/module-summary.html?is-external=true\" "
1236                 + "class=\"externalLink\"><code>Link to java.base module</code></a>");
1237 }
1238 }