Fri, 04 Oct 2013 13:32:30 -0700
8008164: Invisible table captions in javadoc-generated html
Reviewed-by: jjg
bpatel@981 | 1 | /* |
bpatel@981 | 2 | * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. |
bpatel@981 | 3 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
bpatel@981 | 4 | * |
bpatel@981 | 5 | * This code is free software; you can redistribute it and/or modify it |
bpatel@981 | 6 | * under the terms of the GNU General Public License version 2 only, as |
bpatel@981 | 7 | * published by the Free Software Foundation. |
bpatel@981 | 8 | * |
bpatel@981 | 9 | * This code is distributed in the hope that it will be useful, but WITHOUT |
bpatel@981 | 10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
bpatel@981 | 11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
bpatel@981 | 12 | * version 2 for more details (a copy is included in the LICENSE file that |
bpatel@981 | 13 | * accompanied this code). |
bpatel@981 | 14 | * |
bpatel@981 | 15 | * You should have received a copy of the GNU General Public License version |
bpatel@981 | 16 | * 2 along with this work; if not, write to the Free Software Foundation, |
bpatel@981 | 17 | * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
bpatel@981 | 18 | * |
bpatel@981 | 19 | * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
bpatel@981 | 20 | * or visit www.oracle.com if you need additional information or have any |
bpatel@981 | 21 | * questions. |
bpatel@981 | 22 | */ |
bpatel@981 | 23 | |
bpatel@981 | 24 | /* |
bpatel@981 | 25 | * @test |
bpatel@981 | 26 | * @bug 6758050 |
bpatel@981 | 27 | * @summary Test HTML output for nested generic types. |
bpatel@981 | 28 | * @author bpatel |
bpatel@981 | 29 | * @library ../lib/ |
bpatel@981 | 30 | * @build JavadocTester TestNestedGenerics |
bpatel@981 | 31 | * @run main TestNestedGenerics |
bpatel@981 | 32 | */ |
bpatel@981 | 33 | |
bpatel@981 | 34 | public class TestNestedGenerics extends JavadocTester { |
bpatel@981 | 35 | |
bpatel@981 | 36 | //Test information. |
bpatel@981 | 37 | private static final String BUG_ID = "6758050"; |
bpatel@981 | 38 | |
bpatel@981 | 39 | //Javadoc arguments. |
bpatel@981 | 40 | private static final String[] ARGS = new String[]{ |
bpatel@981 | 41 | "-d", BUG_ID, "-source", "1.5", "-sourcepath", SRC_DIR, |
bpatel@981 | 42 | "pkg" |
bpatel@981 | 43 | }; |
bpatel@981 | 44 | |
bpatel@981 | 45 | //Input for string search tests. |
bpatel@981 | 46 | private static final String[][] TEST = { |
bpatel@981 | 47 | {BUG_ID + FS + "pkg" + FS + "NestedGenerics.html", |
bpatel@981 | 48 | "<div class=\"block\">Contains <a " + |
bpatel@981 | 49 | "href=\"../pkg/NestedGenerics.html#foo(java.util.Map)\"><code>foo" + |
bpatel@981 | 50 | "(java.util.Map<A, java.util.Map<A, A>>)</code></a></div>" |
bpatel@981 | 51 | } |
bpatel@981 | 52 | }; |
bpatel@981 | 53 | private static final String[][] NEGATED_TEST = NO_TEST; |
bpatel@981 | 54 | |
bpatel@981 | 55 | /** |
bpatel@981 | 56 | * The entry point of the test. |
bpatel@981 | 57 | * @param args the array of command line arguments. |
bpatel@981 | 58 | */ |
bpatel@981 | 59 | public static void main(String[] args) { |
bpatel@981 | 60 | TestNestedGenerics tester = new TestNestedGenerics(); |
bpatel@981 | 61 | run(tester, ARGS, TEST, NEGATED_TEST); |
bpatel@981 | 62 | tester.printSummary(); |
bpatel@981 | 63 | } |
bpatel@981 | 64 | |
bpatel@981 | 65 | /** |
bpatel@981 | 66 | * {@inheritDoc} |
bpatel@981 | 67 | */ |
bpatel@981 | 68 | public String getBugId() { |
bpatel@981 | 69 | return BUG_ID; |
bpatel@981 | 70 | } |
bpatel@981 | 71 | |
bpatel@981 | 72 | /** |
bpatel@981 | 73 | * {@inheritDoc} |
bpatel@981 | 74 | */ |
bpatel@981 | 75 | public String getBugName() { |
bpatel@981 | 76 | return getClass().getName(); |
bpatel@981 | 77 | } |
bpatel@981 | 78 | } |