1 /* 2 * Copyright (c) 2015, 2019, 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 8072945 8081854 8141492 8148985 8150188 4649116 8173707 8151743 8169819 8183037 8182765 8196202 27 * 8202624 8210047 8184205 8221871 8223733 8223378 28 * @summary Test the version of HTML generated by the javadoc tool. 29 * @library ../../lib 30 * @modules jdk.javadoc/jdk.javadoc.internal.tool 31 * @build javadoc.tester.* 32 * @run main TestHtmlVersion 33 */ 34 35 import javadoc.tester.JavadocTester; 36 37 public class TestHtmlVersion extends JavadocTester { 38 39 public static void main(String... args) throws Exception { 40 TestHtmlVersion tester = new TestHtmlVersion(); 41 tester.runTests(); 42 } 43 44 @Test 45 public void test1() { 46 javadoc("-d", "out-1", 47 "-private", 48 "-linksource", 49 "-sourcepath", testSrc, 50 "-use", 51 "pkg", "pkg1", "pkg2", "pkg3"); 52 checkExit(Exit.OK); 53 54 html5Output(); 55 html5NegatedOutput(); 56 } 57 58 @Test 59 public void test4() { 60 javadoc("-d", "out-4", 61 "-private", 62 "-linksource", 63 "-sourcepath", testSrc, 64 "-use", 65 "pkg3"); 66 checkExit(Exit.OK); 67 } 68 69 void html5Output() { 70 // Test for overview-summary page 71 checkOutput("index.html", true, 72 "<!DOCTYPE HTML>", 73 "<meta name=\"dc.created\"", 74 "<a id=\"navbar.top.firstrow\">\n" 75 + "<!-- -->\n" 76 + "</a>", 77 "<div class=\"overviewSummary\">\n" 78 + "<table>\n" 79 + "<caption>", 80 "<header role=\"banner\" class=\"flexHeader\">\n" 81 + "<nav role=\"navigation\">\n" 82 + "<!-- ========= START OF TOP NAVBAR ======= -->", 83 "<footer role=\"contentinfo\">\n" 84 + "<nav role=\"navigation\">\n" 85 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 86 87 // Test for package-summary page 88 checkOutput("pkg/package-summary.html", true, 89 "<!DOCTYPE HTML>", 90 "<meta name=\"dc.created\"", 91 "<a id=\"navbar.top.firstrow\">\n" 92 + "<!-- -->\n" 93 + "</a>", 94 "<div class=\"typeSummary\">\n<table>", 95 "<header role=\"banner\" class=\"flexHeader\">\n" 96 + "<nav role=\"navigation\">\n" 97 + "<!-- ========= START OF TOP NAVBAR ======= -->", 98 "<main role=\"main\">\n" 99 + "<div class=\"header\">", 100 "<section class=\"packageDescription\"><a id=\"package.description\">\n" 101 + "<!-- -->\n" 102 + "</a>\n" 103 + "<div class=\"block\">Test package.</div>", 104 "<footer role=\"contentinfo\">\n" 105 + "<nav role=\"navigation\">\n" 106 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 107 // No package description 108 checkOutput("pkg1/package-summary.html", true, 109 "<div class=\"contentContainer\">\n" 110 + "<section class=\"summary\">\n" 111 + "<ul class=\"blockList\">\n" 112 + "<li class=\"blockList\">\n" 113 + "<div class=\"typeSummary\">\n<table>\n" 114 + "<caption><span>Class Summary</span><span class=\"tabEnd\"> </span></caption>"); 115 116 // Test for package-tree page 117 checkOutput("pkg/package-tree.html", true, 118 "<!DOCTYPE HTML>", 119 "<meta name=\"dc.created\"", 120 "<a id=\"navbar.top.firstrow\">\n" 121 + "<!-- -->\n" 122 + "</a>", 123 "<li class=\"circle\">", 124 "<header role=\"banner\" class=\"flexHeader\">\n" 125 + "<nav role=\"navigation\">\n" 126 + "<!-- ========= START OF TOP NAVBAR ======= -->", 127 "<main role=\"main\">\n" 128 + "<div class=\"header\">", 129 "<section class=\"hierarchy\">\n" 130 + "<h2 title=\"Class Hierarchy\">Class Hierarchy</h2>", 131 "<section class=\"hierarchy\">\n" 132 + "<h2 title=\"Interface Hierarchy\">Interface Hierarchy</h2>", 133 "<section class=\"hierarchy\">\n" 134 + "<h2 title=\"Annotation Type Hierarchy\">Annotation Type Hierarchy</h2>", 135 "<section class=\"hierarchy\">\n" 136 + "<h2 title=\"Enum Hierarchy\">Enum Hierarchy</h2>", 137 "<footer role=\"contentinfo\">\n" 138 + "<nav role=\"navigation\">\n" 139 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 140 141 // Test for package-use page 142 checkOutput("pkg1/package-use.html", true, 143 "<!DOCTYPE HTML>", 144 "<meta name=\"dc.created\"", 145 "<a id=\"navbar.top.firstrow\">\n" 146 + "<!-- -->\n" 147 + "</a>", 148 "<div class=\"useSummary\">\n<table>", 149 "<header role=\"banner\" class=\"flexHeader\">\n" 150 + "<nav role=\"navigation\">\n" 151 + "<!-- ========= START OF TOP NAVBAR ======= -->", 152 "<main role=\"main\">\n" 153 + "<div class=\"header\">", 154 "<footer role=\"contentinfo\">\n" 155 + "<nav role=\"navigation\">\n" 156 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 157 158 // Test for constant-values page 159 checkOutput("constant-values.html", true, 160 "<!DOCTYPE HTML>", 161 "<meta name=\"dc.created\"", 162 "<a id=\"navbar.top.firstrow\">\n" 163 + "<!-- -->\n" 164 + "</a>", 165 "<div class=\"constantsSummary\">\n<table>", 166 "<header role=\"banner\" class=\"flexHeader\">\n" 167 + "<nav role=\"navigation\">\n" 168 + "<!-- ========= START OF TOP NAVBAR ======= -->", 169 "<main role=\"main\">\n" 170 + "<div class=\"header\">", 171 "<section class=\"packages\">\n" 172 + "<h2 title=\"Contents\">Contents</h2>\n", 173 "<section class=\"constantsSummary\">\n" 174 + "<h2 title=\"pkg\">pkg.*</h2>\n", 175 "<footer role=\"contentinfo\">\n" 176 + "<nav role=\"navigation\">\n" 177 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 178 179 // Test for deprecated-list page 180 checkOutput("deprecated-list.html", true, 181 "<!DOCTYPE HTML>", 182 "<meta name=\"dc.created\"", 183 "<a id=\"navbar.top.firstrow\">\n" 184 + "<!-- -->\n" 185 + "</a>", 186 "<div class=\"deprecatedSummary\">\n<table>", 187 "<header role=\"banner\" class=\"flexHeader\">\n" 188 + "<nav role=\"navigation\">\n" 189 + "<!-- ========= START OF TOP NAVBAR ======= -->", 190 "<main role=\"main\">\n" 191 + "<div class=\"header\">", 192 "<footer role=\"contentinfo\">\n" 193 + "<nav role=\"navigation\">\n" 194 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 195 196 // Test for serialized-form page 197 checkOutput("serialized-form.html", true, 198 "<!DOCTYPE HTML>", 199 "<meta name=\"dc.created\"", 200 "<a id=\"navbar.top.firstrow\">\n" 201 + "<!-- -->\n" 202 + "</a>", 203 "<header role=\"banner\" class=\"flexHeader\">\n" 204 + "<nav role=\"navigation\">\n" 205 + "<!-- ========= START OF TOP NAVBAR ======= -->", 206 "<main role=\"main\">\n" 207 + "<div class=\"header\">", 208 "<section class=\"serializedPackageContainer\">\n" 209 + "<h2 title=\"Package\">Package pkg</h2>\n", 210 "<footer role=\"contentinfo\">\n" 211 + "<nav role=\"navigation\">\n" 212 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 213 214 // Test for overview-tree page 215 checkOutput("overview-tree.html", true, 216 "<!DOCTYPE HTML>", 217 "<meta name=\"dc.created\"", 218 "<a id=\"navbar.top.firstrow\">\n" 219 + "<!-- -->\n" 220 + "</a>", 221 "<li class=\"circle\">", 222 "<header role=\"banner\" class=\"flexHeader\">\n" 223 + "<nav role=\"navigation\">\n" 224 + "<!-- ========= START OF TOP NAVBAR ======= -->", 225 "<main role=\"main\">\n" 226 + "<div class=\"header\">", 227 "<section class=\"hierarchy\">\n" 228 + "<h2 title=\"Class Hierarchy\">Class Hierarchy</h2>\n", 229 "<section class=\"hierarchy\">\n" 230 + "<h2 title=\"Interface Hierarchy\">Interface Hierarchy</h2>\n", 231 "<section class=\"hierarchy\">\n" 232 + "<h2 title=\"Annotation Type Hierarchy\">Annotation Type Hierarchy</h2>\n", 233 "<section class=\"hierarchy\">\n" 234 + "<h2 title=\"Enum Hierarchy\">Enum Hierarchy</h2>\n", 235 "<footer role=\"contentinfo\">\n" 236 + "<nav role=\"navigation\">\n" 237 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 238 239 // Test for index-all page 240 checkOutput("index-all.html", true, 241 "<!DOCTYPE HTML>", 242 "<meta name=\"dc.created\"", 243 "<a id=\"navbar.top.firstrow\">\n" 244 + "<!-- -->\n" 245 + "</a>", 246 "<header role=\"banner\" class=\"flexHeader\">\n" 247 + "<nav role=\"navigation\">\n" 248 + "<!-- ========= START OF TOP NAVBAR ======= -->", 249 "</header>\n" 250 + "<div class=\"flexContent\">\n" 251 + "<main role=\"main\">", 252 "<footer role=\"contentinfo\">\n" 253 + "<nav role=\"navigation\">\n" 254 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 255 256 // Test for src-html page 257 checkOutput("src-html/pkg/AnotherClass.html", true, 258 "<!DOCTYPE HTML>", 259 "<main role=\"main\">\n" 260 + "<div class=\"sourceContainer\">"); 261 262 // Test for help-doc page 263 checkOutput("help-doc.html", true, 264 "<!DOCTYPE HTML>", 265 "<meta name=\"dc.created\"", 266 "<a id=\"navbar.top.firstrow\">\n" 267 + "<!-- -->\n" 268 + "</a>", 269 "<header role=\"banner\" class=\"flexHeader\">\n" 270 + "<nav role=\"navigation\">\n" 271 + "<!-- ========= START OF TOP NAVBAR ======= -->", 272 "<main role=\"main\">\n" 273 + "<div class=\"header\">", 274 "<section class=\"helpSection\">\n" 275 + "<h2>Overview</h2>\n", 276 "<section class=\"helpSection\">\n" 277 + "<h2>Package</h2>\n", 278 "<section class=\"helpSection\">\n" 279 + "<h2>Class or Interface</h2>\n", 280 "<footer role=\"contentinfo\">\n" 281 + "<nav role=\"navigation\">\n" 282 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 283 284 // Test for a regular class page and members (nested class, field, constructore and method) 285 checkOutput("pkg/AnotherClass.html", true, 286 "<!DOCTYPE HTML>", 287 "<meta name=\"dc.created\"", 288 "<a id=\"navbar.top.firstrow\">\n" 289 + "<!-- -->\n" 290 + "</a>", 291 "<header role=\"banner\" class=\"flexHeader\">\n" 292 + "<nav role=\"navigation\">\n" 293 + "<!-- ========= START OF TOP NAVBAR ======= -->", 294 "<main role=\"main\">\n" 295 + "<!-- ======== START OF CLASS DATA ======== -->\n" 296 + "<div class=\"header\">", 297 "<section class=\"nestedClassSummary\"><a id=\"nested.class.summary\">\n" 298 + "<!-- -->\n" 299 + "</a>\n" 300 + "<h2>Nested Class Summary</h2>\n" 301 + "<div class=\"memberSummary\">\n<table>", 302 "<section class=\"fieldSummary\"><a id=\"field.summary\">\n" 303 + "<!-- -->\n" 304 + "</a>\n" 305 + "<h2>Field Summary</h2>\n" 306 + "<div class=\"memberSummary\">\n<table>", 307 "<section class=\"constructorSummary\"><a id=\"constructor.summary\">\n" 308 + "<!-- -->\n" 309 + "</a>\n" 310 + "<h2>Constructor Summary</h2>\n" 311 + "<div class=\"memberSummary\">\n<table>", 312 "<section class=\"methodSummary\"><a id=\"method.summary\">\n" 313 + "<!-- -->\n" 314 + "</a>\n" 315 + "<h2>Method Summary</h2>", 316 "<section class=\"fieldDetails\">" 317 + "<a id=\"field.detail\">\n" 318 + "<!-- -->\n" 319 + "</a>\n" 320 + "<h2>Field Details</h2>\n", 321 "<section class=\"constructorDetails\">" 322 + "<a id=\"constructor.detail\">\n" 323 + "<!-- -->\n" 324 + "</a>\n" 325 + "<h2>Constructor Details</h2>\n", 326 "<section class=\"methodDetails\">" 327 + "<a id=\"method.detail\">\n" 328 + "<!-- -->\n" 329 + "</a>\n" 330 + "<h2>Method Details</h2>\n", 331 "<footer role=\"contentinfo\">\n" 332 + "<nav role=\"navigation\">\n" 333 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 334 335 // Test for enum page 336 checkOutput("pkg/AnotherClass.ModalExclusionType.html", true, 337 "<!DOCTYPE HTML>", 338 "<meta name=\"dc.created\"", 339 "<a id=\"navbar.top.firstrow\">\n" 340 + "<!-- -->\n" 341 + "</a>", 342 "<header role=\"banner\" class=\"flexHeader\">\n" 343 + "<nav role=\"navigation\">\n" 344 + "<!-- ========= START OF TOP NAVBAR ======= -->", 345 "<main role=\"main\">\n" 346 + "<!-- ======== START OF CLASS DATA ======== -->\n" 347 + "<div class=\"header\">", 348 "<section class=\"constantsSummary\"><a id=\"enum.constant.summary\">\n" 349 + "<!-- -->\n" 350 + "</a>\n" 351 + "<h2>Enum Constant Summary</h2>\n" 352 + "<div class=\"memberSummary\">\n", 353 "<table aria-labelledby=\"t0\">\n", 354 "<section class=\"methodSummary\"><a id=\"method.summary\">\n" 355 + "<!-- -->\n" 356 + "</a>\n" 357 + "<h2>Method Summary</h2>\n" 358 + "<div class=\"memberSummary\">\n", 359 "<table aria-labelledby=\"t0\">", 360 "<section class=\"constantDetails\">" 361 + "<a id=\"enum.constant.detail\">\n" 362 + "<!-- -->\n" 363 + "</a>\n" 364 + "<h2>Enum Constant Details</h2>\n", 365 "<section class=\"methodDetails\">" 366 + "<a id=\"method.detail\">\n" 367 + "<!-- -->\n" 368 + "</a>\n" 369 + "<h2>Method Details</h2>\n", 370 "<footer role=\"contentinfo\">\n" 371 + "<nav role=\"navigation\">\n" 372 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 373 374 // Test for interface page 375 checkOutput("pkg2/Interface.html", true, 376 "<!DOCTYPE HTML>", 377 "<meta name=\"dc.created\"", 378 "<a id=\"navbar.top.firstrow\">\n" 379 + "<!-- -->\n" 380 + "</a>", 381 "<header role=\"banner\" class=\"flexHeader\">\n" 382 + "<nav role=\"navigation\">\n" 383 + "<!-- ========= START OF TOP NAVBAR ======= -->", 384 "<main role=\"main\">\n" 385 + "<!-- ======== START OF CLASS DATA ======== -->\n" 386 + "<div class=\"header\">", 387 "<section class=\"methodSummary\"><a id=\"method.summary\">\n" 388 + "<!-- -->\n" 389 + "</a>\n" 390 + "<h2>Method Summary</h2>\n" 391 + "<div class=\"memberSummary\">\n", 392 "<table aria-labelledby=\"t0\">\n", 393 "<section class=\"methodDetails\">" 394 + "<a id=\"method.detail\">\n" 395 + "<!-- -->\n" 396 + "</a>\n" 397 + "<h2>Method Details</h2>\n", 398 "<footer role=\"contentinfo\">\n" 399 + "<nav role=\"navigation\">\n" 400 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 401 402 // Test for error page 403 checkOutput("pkg/TestError.html", true, 404 "<!DOCTYPE HTML>", 405 "<meta name=\"dc.created\"", 406 "<a id=\"navbar.top.firstrow\">\n" 407 + "<!-- -->\n" 408 + "</a>", 409 "<header role=\"banner\" class=\"flexHeader\">\n" 410 + "<nav role=\"navigation\">\n" 411 + "<!-- ========= START OF TOP NAVBAR ======= -->", 412 "<main role=\"main\">\n" 413 + "<!-- ======== START OF CLASS DATA ======== -->\n" 414 + "<div class=\"header\">", 415 "<section class=\"constructorSummary\"><a id=\"constructor.summary\">\n" 416 + "<!-- -->\n" 417 + "</a>\n" 418 + "<h2>Constructor Summary</h2>", 419 "<section class=\"constructorDetails\">" 420 + "<a id=\"constructor.detail\">\n" 421 + "<!-- -->\n" 422 + "</a>\n" 423 + "<h2>Constructor Details</h2>\n", 424 "<footer role=\"contentinfo\">\n" 425 + "<nav role=\"navigation\">\n" 426 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 427 428 // Test for exception page 429 checkOutput("pkg/TestException.html", true, 430 "<!DOCTYPE HTML>", 431 "<meta name=\"dc.created\"", 432 "<a id=\"navbar.top.firstrow\">\n" 433 + "<!-- -->\n" 434 + "</a>", 435 "<header role=\"banner\" class=\"flexHeader\">\n" 436 + "<nav role=\"navigation\">\n" 437 + "<!-- ========= START OF TOP NAVBAR ======= -->", 438 "<main role=\"main\">\n" 439 + "<!-- ======== START OF CLASS DATA ======== -->\n" 440 + "<div class=\"header\">", 441 "<section class=\"constructorSummary\"><a id=\"constructor.summary\">\n" 442 + "<!-- -->\n" 443 + "</a>\n" 444 + "<h2>Constructor Summary</h2>", 445 "<section class=\"constructorDetails\">" 446 + "<a id=\"constructor.detail\">\n" 447 + "<!-- -->\n" 448 + "</a>\n" 449 + "<h2>Constructor Details</h2>\n", 450 "<footer role=\"contentinfo\">\n" 451 + "<nav role=\"navigation\">\n" 452 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 453 454 // Test for annotation page 455 checkOutput("pkg2/TestAnnotationType.html", true, 456 "<!DOCTYPE HTML>", 457 "<meta name=\"dc.created\"", 458 "<a id=\"navbar.top.firstrow\">\n" 459 + "<!-- -->\n" 460 + "</a>", 461 "<header role=\"banner\" class=\"flexHeader\">\n" 462 + "<nav role=\"navigation\">\n" 463 + "<!-- ========= START OF TOP NAVBAR ======= -->", 464 "<main role=\"main\">\n" 465 + "<!-- ======== START OF CLASS DATA ======== -->\n" 466 + "<div class=\"header\">", 467 "<section class=\"memberSummary\"><a id=\"annotation.type.required.element.summary\">\n" 468 + "<!-- -->\n" 469 + "</a>\n" 470 + "<h2>Required Element Summary</h2>\n" 471 + "<div class=\"memberSummary\">\n<table>", 472 "<section class=\"memberSummary\"><a id=\"annotation.type.optional.element.summary\">\n" 473 + "<!-- -->\n" 474 + "</a>\n" 475 + "<h2>Optional Element Summary</h2>\n" 476 + "<div class=\"memberSummary\">\n<table>", 477 "<section class=\"memberDetails\">" 478 + "<a id=\"annotation.type.element.detail\">\n" 479 + "<!-- -->\n" 480 + "</a>\n" 481 + "<h2>Element Details</h2>", 482 "<footer role=\"contentinfo\">\n" 483 + "<nav role=\"navigation\">\n" 484 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 485 486 // Test for class use page 487 checkOutput("pkg1/class-use/RegClass.html", true, 488 "<!DOCTYPE HTML>", 489 "<meta name=\"dc.created\"", 490 "<a id=\"navbar.top.firstrow\">\n" 491 + "<!-- -->\n" 492 + "</a>", 493 "<header role=\"banner\" class=\"flexHeader\">\n" 494 + "<nav role=\"navigation\">\n" 495 + "<!-- ========= START OF TOP NAVBAR ======= -->", 496 "<main role=\"main\">\n" 497 + "<div class=\"header\">", 498 "<div class=\"useSummary\">\n<table>", 499 "<section class=\"detail\"><a id=\"pkg\">\n" 500 + "<!-- -->\n" 501 + "</a>\n" 502 + "<h2>Uses of <a href=\"../RegClass.html\" title=\"class in pkg1\">RegClass</a> in <a href=\"../../pkg/package-summary.html\">pkg</a></h2>\n" 503 + "<div class=\"useSummary\">\n<table>", 504 "<footer role=\"contentinfo\">\n" 505 + "<nav role=\"navigation\">\n" 506 + "<!-- ======= START OF BOTTOM NAVBAR ====== -->"); 507 } 508 509 void html5NegatedOutput() { 510 // Negated test for overview-summary page 511 checkOutput("overview-summary.html", false, 512 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 513 "<meta name=\"date\"", 514 "<a name=\"navbar.top.firstrow\">\n" 515 + "<!-- -->\n" 516 + "</a>", 517 "<table summary=\"Package Summary table, listing packages, and an explanation\">\n" 518 + "<caption>", 519 "</noscript>\n" 520 + "<!-- ========= START OF TOP NAVBAR ======= -->"); 521 522 // Negated test for package-summary page 523 checkOutput("pkg/package-summary.html", false, 524 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 525 "<meta name=\"date\"", 526 "<a name=\"navbar.top.firstrow\">\n" 527 + "<!-- -->\n" 528 + "</a>", 529 "<section>\n" 530 + "<h2 title=\"PackagAnotherClass.ModalExclusionType.htmle pkg Description\">Package pkg Description</h2>\n", 531 "<div class=\"typeSummary\">\n<table summary=\"Interface Summary table, listing interfaces, and an explanation\">", 532 "<div class=\"typeSummary\">\n<table summary=\"Class Summary table, listing classes, and an explanation\">", 533 "<div class=\"typeSummary\">\n<table summary=\"Enum Summary table, listing enums, and an explanation\">", 534 "<div class=\"typeSummary\">\n<table summary=\"Exception Summary table, listing exceptions, and an explanation\">", 535 "<div class=\"typeSummary\">\n<table summary=\"Error Summary table, listing errors, and an explanation\">", 536 "<div class=\"typeSummary\">\n<table summary=\"Annotation Types Summary table, listing annotation types, and an explanation\">"); 537 538 // Negated test for package-tree page 539 checkOutput("pkg/package-tree.html", false, 540 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 541 "<meta name=\"date\"", 542 "<a name=\"navbar.top.firstrow\">\n" 543 + "<!-- -->\n" 544 + "</a>"); 545 546 // Negated test for package-use page 547 checkOutput("pkg1/package-use.html", false, 548 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 549 "<meta name=\"date\"", 550 "<a name=\"navbar.top.firstrow\">\n" 551 + "<!-- -->\n" 552 + "</a>", 553 "<div class=\"useSummary\">\n" 554 + "<table summary=\"Use table, listing packages, and an explanation\">"); 555 556 // Negated test for constant-values page 557 checkOutput("constant-values.html", false, 558 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 559 "<meta name=\"date\"", 560 "<a name=\"navbar.top.firstrow\">\n" 561 + "<!-- -->\n" 562 + "</a>", 563 "<!-- ========= END OF TOP NAVBAR ========= -->\n" 564 + "</div>\n" 565 + "<div class=\"header\">", 566 "<div class=\"constantsSummary\">\n" 567 + "<table summary=\"Constant Field Values table, listing constant fields, and values\">"); 568 569 // Negated test for deprecated-list page 570 checkOutput("deprecated-list.html", false, 571 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 572 "<meta name=\"date\"", 573 "<a name=\"navbar.top.firstrow\">\n" 574 + "<!-- -->\n" 575 + "</a>", 576 "<!-- ========= END OF TOP NAVBAR ========= -->\n" 577 + "</div>\n" 578 + "<div class=\"header\">\n" 579 + "<h1 title=\"Deprecated API\" class=\"title\">Deprecated API</h1>\n" 580 + "<h2 title=\"Contents\">Contents</h2>", 581 "<div class=\"deprecatedSummary\">\n<table summary=\"Classes table, listing classes, and an explanation\">", 582 "<div class=\"deprecatedSummary\">\n<table summary=\"Enums table, listing enums, and an explanation\">", 583 "<div class=\"deprecatedSummary\">\n<table summary=\"Exceptions table, listing exceptions, and an explanation\">", 584 "<div class=\"deprecatedSummary\">\n<table summary=\"Errors table, listing errors, and an explanation\">", 585 "<div class=\"deprecatedSummary\">\n<table summary=\"Annotation Types table, listing annotation types, and an explanation\">", 586 "<div class=\"deprecatedSummary\">\n<table summary=\"Fields table, listing fields, and an explanation\">", 587 "<div class=\"deprecatedSummary\">\n<table summary=\"Methods table, listing methods, and an explanation\">", 588 "<div class=\"deprecatedSummary\">\n<table summary=\"Constructors table, listing constructors, and an explanation\">", 589 "<div class=\"deprecatedSummary\">\n<table summary=\"Enum Constants table, listing enum constants, and an explanation\">", 590 "<div class=\"deprecatedSummary\">\n<table summary=\"Annotation Type Elements table, listing annotation type elements, and an explanation\">"); 591 592 // Negated test for serialized-form page 593 checkOutput("serialized-form.html", false, 594 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 595 "<meta name=\"date\"", 596 "<a name=\"navbar.top.firstrow\">\n" 597 + "<!-- -->\n" 598 + "</a>", 599 "<!-- ========= END OF TOP NAVBAR ========= -->\n" 600 + "</div>\n" 601 + "<div class=\"header\">", 602 "<li class=\"blockList\">\n" 603 + "<h2 title=\"Package\">Package pkg</h2>"); 604 605 // Negated test for overview-tree page 606 checkOutput("overview-tree.html", false, 607 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 608 "<meta name=\"date\"", 609 "<a name=\"navbar.top.firstrow\">\n" 610 + "<!-- -->\n" 611 + "</a>", 612 "<!-- ========= END OF TOP NAVBAR ========= -->\n" 613 + "</div>\n" 614 + "<div class=\"header\">", 615 "<div class=\"contentContainer\">\n" 616 + "<h2 title=\"Class Hierarchy\">Class Hierarchy</h2>", 617 "</ul>\n" 618 + "<h2 title=\"Interface Hierarchy\">Interface Hierarchy</h2>", 619 "</ul>\n" 620 + "<h2 title=\"Enum Hierarchy\">Enum Hierarchy</h2>"); 621 622 // Negated test for index-all page 623 checkOutput("index-all.html", false, 624 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 625 "<meta name=\"date\"", 626 "<a name=\"navbar.top.firstrow\">\n" 627 + "<!-- -->\n" 628 + "</a>", 629 "<!-- ========= END OF TOP NAVBAR ========= -->\n" 630 + "</div>\n" 631 + "<div class=\"contentContainer\">"); 632 633 // Negated test for src-html page 634 checkOutput("src-html/pkg/AnotherClass.html", false, 635 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 636 "<body>\n" 637 + "<div class=\"sourceContainer\">"); 638 639 // Negated test for help-doc page 640 checkOutput("help-doc.html", false, 641 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 642 "<meta name=\"date\"", 643 "<a name=\"navbar.top.firstrow\">\n" 644 + "<!-- -->\n" 645 + "</a>", 646 "<!-- ========= END OF TOP NAVBAR ========= -->\n" 647 + "</div>\n" 648 + "<div class=\"header\">", 649 "<ul class=\"blockList\">\n" 650 + "<li class=\"blockList\">\n" 651 + "<h2>Overview</h2>", 652 "<li class=\"blockList\">\n" 653 + "<h2>Package</h2>", 654 "<li class=\"blockList\">\n" 655 + "<h2>Class/Interface</h2>"); 656 657 // Negated test for a regular class page and members (nested class, field, constructore and method) 658 checkOutput("pkg/AnotherClass.html", false, 659 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 660 "<meta name=\"date\"", 661 "<a name=\"navbar.top.firstrow\">\n" 662 + "<!-- -->\n" 663 + "</a>", 664 "<!-- ======== NESTED CLASS SUMMARY ======== -->\n" 665 + "<ul class=\"blockList\">\n" 666 + "<li class=\"blockList\"><a name=\"nested.class.summary\">\n" 667 + "<!-- -->\n" 668 + "</a>\n" 669 + "<h2>Nested Class Summary</h2>\n" 670 + "<div class=\"memberSummary\">\n" 671 + "<table summary=\"Nested Class Summary table, listing nested classes, and an explanation\">", 672 "<!-- =========== FIELD SUMMARY =========== -->\n" 673 + "<ul class=\"blockList\">\n" 674 + "<li class=\"blockList\"><a name=\"field.summary\">\n" 675 + "<!-- -->\n" 676 + "</a>\n" 677 + "<h2>Field Summary</h2>\n" 678 + "<div class=\"memberSummary\">\n" 679 + "<table summary=\"Field Summary table, listing fields, and an explanation\">", 680 "<!-- ======== CONSTRUCTOR SUMMARY ======== -->\n" 681 + "<ul class=\"blockList\">\n" 682 + "<li class=\"blockList\"><a name=\"constructor.summary\">\n" 683 + "<!-- -->\n" 684 + "</a>\n" 685 + "<h2>Constructor Summary</h2>\n" 686 + "<div class=\"memberSummary\">\n" 687 + "<table summary=\"Constructor Summary table, listing constructors, and an explanation\">", 688 "<!-- ========== METHOD SUMMARY =========== -->\n" 689 + "<ul class=\"blockList\">\n" 690 + "<li class=\"blockList\"><a name=\"method.summary\">\n" 691 + "<!-- -->\n" 692 + "</a>\n" 693 + "<h2>Method Summary</h2>\n" 694 + "<div class=\"memberSummary\">\n" 695 + "<table summary=\"Method Summary table, listing methods, and an explanation\">", 696 "<!-- ============ FIELD DETAIL =========== -->\n" 697 + "<ul class=\"blockList\">\n" 698 + "<li class=\"blockList\"><a name=\"field.detail\">\n" 699 + "<!-- -->\n" 700 + "</a>\n" 701 + "<h2>Field Details</h2>", 702 "<!-- ========= CONSTRUCTOR DETAIL ======== -->\n" 703 + "<ul class=\"blockList\">\n" 704 + "<li class=\"blockList\"><a name=\"constructor.detail\">\n" 705 + "<!-- -->\n" 706 + "</a>\n" 707 + "<h2>Constructor Details</h2>", 708 "<!-- ============ METHOD DETAIL ========== -->\n" 709 + "<ul class=\"blockList\">\n" 710 + "<li class=\"blockList\"><a name=\"method.detail\">\n" 711 + "<!-- -->\n" 712 + "</a>\n" 713 + "<h2>Method Details</h2>"); 714 715 // Negated test for enum page 716 checkOutput("pkg/AnotherClass.ModalExclusionType.html", false, 717 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 718 "<meta name=\"date\"", 719 "<a name=\"navbar.top.firstrow\">\n" 720 + "<!-- -->\n" 721 + "</a>", 722 "<!-- =========== ENUM CONSTANT SUMMARY =========== -->\n" 723 + "<ul class=\"blockList\">\n" 724 + "<li class=\"blockList\"><a name=\"enum.constant.summary\">\n" 725 + "<!-- -->\n" 726 + "</a>\n" 727 + "<h2>Enum Constant Summary</h2>\n" 728 + "<div class=\"memberSummary\">\n" 729 + "<table summary=\"Enum Constant Summary table, listing enum constants, and an explanation\">", 730 "<!-- ========== METHOD SUMMARY =========== -->\n" 731 + "<ul class=\"blockList\">\n" 732 + "<li class=\"blockList\"><a name=\"method.summary\">\n" 733 + "<!-- -->\n" 734 + "</a>\n" 735 + "<h2>Method Summary</h2>\n" 736 + "<div class=\"memberSummary\">\n" 737 + "<table summary=\"Method Summary table, listing methods, and an explanation\">", 738 "<!-- ============ ENUM CONSTANT DETAIL =========== -->\n" 739 + "<ul class=\"blockList\">\n" 740 + "<li class=\"blockList\"><a name=\"enum.constant.detail\">\n" 741 + "<!-- -->\n" 742 + "</a>\n" 743 + "<h2>Enum Constant Details</h2>", 744 "<!-- ============ METHOD DETAIL ========== -->\n" 745 + "<ul class=\"blockList\">\n" 746 + "<li class=\"blockList\"><a name=\"method.detail\">\n" 747 + "<!-- -->\n" 748 + "</a>\n" 749 + "<h2>Method Details</h2>"); 750 751 // Negated test for interface page 752 checkOutput("pkg2/Interface.html", false, 753 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 754 "<meta name=\"date\"", 755 "<a name=\"navbar.top.firstrow\">\n" 756 + "<!-- -->\n" 757 + "</a>", 758 "<!-- ========== METHOD SUMMARY =========== -->\n" 759 + "<ul class=\"blockList\">\n" 760 + "<li class=\"blockList\"><a name=\"method.summary\">\n" 761 + "<!-- -->\n" 762 + "</a>\n" 763 + "<h2>Method Summary</h2>\n" 764 + "<div class=\"memberSummary\">\n" 765 + "<table summary=\"Method Summary table, listing methods, and an explanation\">", 766 "<!-- ============ METHOD DETAIL ========== -->\n" 767 + "<ul class=\"blockList\">\n" 768 + "<li class=\"blockList\"><a name=\"method.detail\">\n" 769 + "<!-- -->\n" 770 + "</a>\n" 771 + "<h2>Method Details</h2>"); 772 773 // Negated test for error page 774 checkOutput("pkg/TestError.html", false, 775 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 776 "<meta name=\"date\"", 777 "<a name=\"navbar.top.firstrow\">\n" 778 + "<!-- -->\n" 779 + "</a>", 780 "<!-- ======== CONSTRUCTOR SUMMARY ======== -->\n" 781 + "<ul class=\"blockList\">\n" 782 + "<li class=\"blockList\"><a name=\"constructor.summary\">\n" 783 + "<!-- -->\n" 784 + "</a>\n" 785 + "<h2>Constructor Summary</h2>", 786 "<!-- ========= CONSTRUCTOR DETAIL ======== -->\n" 787 + "<ul class=\"blockList\">\n" 788 + "<li class=\"blockList\"><a name=\"constructor.detail\">\n" 789 + "<!-- -->\n" 790 + "</a>\n" 791 + "<h2>Constructor Details</h2>"); 792 793 // Negated test for exception page 794 checkOutput("pkg/TestException.html", false, 795 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 796 "<meta name=\"date\"", 797 "<a name=\"navbar.top.firstrow\">\n" 798 + "<!-- -->\n" 799 + "</a>", 800 "<!-- ======== CONSTRUCTOR SUMMARY ======== -->\n" 801 + "<ul class=\"blockList\">\n" 802 + "<li class=\"blockList\"><a name=\"constructor.summary\">\n" 803 + "<!-- -->\n" 804 + "</a>\n" 805 + "<h2>Constructor Summary</h2>", 806 "<!-- ========= CONSTRUCTOR DETAIL ======== -->\n" 807 + "<ul class=\"blockList\">\n" 808 + "<li class=\"blockList\"><a name=\"constructor.detail\">\n" 809 + "<!-- -->\n" 810 + "</a>\n" 811 + "<h2>Constructor Details</h2>"); 812 813 // Negated test for annotation page 814 checkOutput("pkg2/TestAnnotationType.html", false, 815 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 816 "<meta name=\"date\"", 817 "<a name=\"navbar.top.firstrow\">\n" 818 + "<!-- -->\n" 819 + "</a>", 820 "<!-- =========== ANNOTATION TYPE REQUIRED MEMBER SUMMARY =========== -->\n" 821 + "<ul class=\"blockList\">\n" 822 + "<li class=\"blockList\"><a name=\"annotation.type.required.element.summary\">\n" 823 + "<!-- -->\n" 824 + "</a>\n" 825 + "<h2>Required Element Summary</h2>\n" 826 + "<div class=\"memberSummary\">\n" 827 + "<table summary=\"Required Element Summary table, listing required elements, and an explanation\">", 828 "<!-- =========== ANNOTATION TYPE OPTIONAL MEMBER SUMMARY =========== -->\n" 829 + "<ul class=\"blockList\">\n" 830 + "<li class=\"blockList\"><a name=\"annotation.type.optional.element.summary\">\n" 831 + "<!-- -->\n" 832 + "</a>\n" 833 + "<h2>Optional Element Summary</h2>\n" 834 + "<div class=\"memberSummary\">\n" 835 + "<table summary=\"Optional Element Summary table, listing optional elements, and an explanation\">", 836 "<!-- ============ ANNOTATION TYPE MEMBER DETAIL =========== -->\n" 837 + "<ul class=\"blockList\">\n" 838 + "<li class=\"blockList\"><a name=\"annotation.type.element.detail\">\n" 839 + "<!-- -->\n" 840 + "</a>\n" 841 + "<h2>Element Details</h2>"); 842 843 // Negated test for class use page 844 checkOutput("pkg1/class-use/RegClass.html", false, 845 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 846 "<meta name=\"date\"", 847 "<a name=\"navbar.top.firstrow\">\n" 848 + "<!-- -->\n" 849 + "</a>", 850 "<!-- ========= END OF TOP NAVBAR ========= -->\n" 851 + "</div>\n" 852 + "<div class=\"header\">", 853 "<div class=\"useSummary\">\n" 854 + "<table summary=\"Use table, listing packages, and an explanation\">", 855 "<li class=\"blockList\"><a name=\"pkg\">\n" 856 + "<!-- -->\n" 857 + "</a>\n" 858 + "<h2>Uses of <a href=\"../RegClass.html\" title=\"class in pkg1\">RegClass</a> in <a href=\"../../pkg/package-summary.html\">pkg</a></h2>\n" 859 + "<div class=\"useSummary\">\n<table summary=\"Use table, listing fields, and an explanation\">"); 860 861 // Negated test for main index page 862 checkOutput("index.html", false, 863 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">", 864 "<body>\n" 865 + "<script type=\"text/javascript\">\n" 866 + "if (targetPage == \"\" || targetPage == \"undefined\")\n" 867 + " window.location.replace('overview-summary.html');\n" 868 + "</script>\n" 869 + "<noscript>JavaScript is disabled on your browser.</noscript>\n" 870 + "<div class=\"mainContainer\">\n"); 871 } 872 }