author | jjg |
Tue, 22 Apr 2014 17:57:40 -0700 | |
changeset 24072 | e7549dcbc4af |
parent 24065 | fc4022e50129 |
child 24399 | af1a0220d0fa |
permissions | -rw-r--r-- |
10 | 1 |
/* |
23971 | 2 |
* Copyright (c) 2002, 2014, Oracle and/or its affiliates. All rights reserved. |
10 | 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 |
* |
|
5520 | 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. |
|
10 | 22 |
*/ |
23 |
||
24 |
/* |
|
25 |
* @test |
|
26 |
* @bug 4496223 4496270 4618686 4720974 4812240 6253614 6253604 |
|
27 |
* @summary <DESC> |
|
28 |
* @author jamieh |
|
29 |
* @library ../lib/ |
|
30 |
* @build JavadocTester |
|
31 |
* @build TestTagInheritence |
|
32 |
* @run main TestTagInheritence |
|
33 |
*/ |
|
34 |
||
35 |
public class TestTagInheritence extends JavadocTester { |
|
36 |
||
37 |
private static final String[] ARGS = new String[] { |
|
24072 | 38 |
"-Xdoclint:none", "-d", OUTPUT_DIR, "-sourcepath", SRC_DIR, "pkg", |
23971 | 39 |
"firstSentence", "firstSentence2" |
10 | 40 |
}; |
41 |
||
42 |
/** |
|
43 |
* The entry point of the test. |
|
44 |
* @param args the array of command line arguments. |
|
45 |
*/ |
|
46 |
public static void main(String[] args) { |
|
47 |
String[][] tests = new String[42][2]; |
|
48 |
//Test bad inheritDoc tag warning. |
|
49 |
tests[0][0]= WARNING_OUTPUT; |
|
50 |
tests[0][1] = "warning - @inheritDoc used but testBadInheritDocTag() " + |
|
51 |
"does not override or implement any method."; |
|
52 |
||
53 |
//Test valid usage of inheritDoc tag. |
|
54 |
for (int i = 1; i < tests.length-2; i++) { |
|
24072 | 55 |
tests[i][0] = "pkg/TestTagInheritence.html"; |
10 | 56 |
tests[i][1] = "Test " + i + " passes"; |
57 |
} |
|
58 |
||
59 |
//First sentence test (6253614) |
|
24072 | 60 |
tests[tests.length - 2][0] = "firstSentence/B.html"; |
7614
cfadc977ca75
6851834: Javadoc doclet needs a structured approach to generate the output HTML.
bpatel
parents:
5520
diff
changeset
|
61 |
tests[tests.length - 2][1] = "<div class=\"block\">First sentence.</div>"; |
10 | 62 |
|
63 |
//Another first sentence test (6253604) |
|
24072 | 64 |
tests[tests.length - 1][0] = "firstSentence2/C.html"; |
7614
cfadc977ca75
6851834: Javadoc doclet needs a structured approach to generate the output HTML.
bpatel
parents:
5520
diff
changeset
|
65 |
tests[tests.length - 1][1] = "<div class=\"block\">First sentence.</div>"; |
10 | 66 |
|
67 |
TestTagInheritence tester = new TestTagInheritence(); |
|
24065
fc4022e50129
8041150: Avoid silly use of static methods in JavadocTester
jjg
parents:
23971
diff
changeset
|
68 |
tester.run(ARGS, tests, NO_TEST); |
10 | 69 |
tester.printSummary(); |
70 |
} |
|
71 |
} |