test/com/sun/javadoc/testPrivateClasses/TestPrivateClasses.java

changeset 766
90af8d87741f
parent 554
9d9f26857129
child 798
4868a36f6fd8
     1.1 --- a/test/com/sun/javadoc/testPrivateClasses/TestPrivateClasses.java	Tue Nov 30 09:38:48 2010 -0800
     1.2 +++ b/test/com/sun/javadoc/testPrivateClasses/TestPrivateClasses.java	Wed Dec 01 11:02:38 2010 -0800
     1.3 @@ -58,50 +58,50 @@
     1.4      private static final String[][] TEST1 = {
     1.5          // Field inheritence from non-public superclass.
     1.6          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
     1.7 -            "<A HREF=\"../pkg/PublicChild.html#fieldInheritedFromParent\">" +
     1.8 -                "fieldInheritedFromParent</A>"
     1.9 +            "<a href=\"../pkg/PublicChild.html#fieldInheritedFromParent\">" +
    1.10 +                "fieldInheritedFromParent</a>"
    1.11          },
    1.12  
    1.13          // Method inheritence from non-public superclass.
    1.14          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
    1.15 -            "<A HREF=\"../pkg/PublicChild.html#methodInheritedFromParent(int)\">" +
    1.16 -                "methodInheritedFromParent</A>"
    1.17 +            "<a href=\"../pkg/PublicChild.html#methodInheritedFromParent(int)\">" +
    1.18 +                "methodInheritedFromParent</a>"
    1.19          },
    1.20  
    1.21          // Field inheritence from non-public superinterface.
    1.22          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicInterface.html",
    1.23 -            "<A HREF=\"../pkg/PublicInterface.html#fieldInheritedFromInterface\">" +
    1.24 -                "fieldInheritedFromInterface</A>"
    1.25 +            "<a href=\"../pkg/PublicInterface.html#fieldInheritedFromInterface\">" +
    1.26 +                "fieldInheritedFromInterface</a>"
    1.27          },
    1.28  
    1.29          // Method inheritence from non-public superinterface.
    1.30          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicInterface.html",
    1.31 -            "<A HREF=\"../pkg/PublicInterface.html#methodInterface(int)\">" +
    1.32 -                "methodInterface</A>"
    1.33 +            "<a href=\"../pkg/PublicInterface.html#methodInterface(int)\">" +
    1.34 +                "methodInterface</a>"
    1.35          },
    1.36  
    1.37          // private class does not show up in tree
    1.38          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
    1.39 -            "<PRE>" + NL +
    1.40 -                "java.lang.Object" + NL +
    1.41 -                "  <IMG SRC=\"../resources/inherit.gif\" " +
    1.42 -                "ALT=\"extended by \"><STRONG>pkg.PublicChild</STRONG>" + NL +
    1.43 -            "</PRE>"
    1.44 +            "<ul class=\"inheritance\">" + NL + "<li>java.lang.Object</li>" + NL +
    1.45 +            "<li>" + NL + "<ul class=\"inheritance\">" + NL + "<li>pkg.PublicChild</li>" + NL +
    1.46 +            "</ul>" + NL + "</li>" + NL + "</ul>"
    1.47          },
    1.48  
    1.49          // Method is documented as though it is declared in the inheriting method.
    1.50          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
    1.51 -            "public void <STRONG>methodInheritedFromParent</STRONG>(int&nbsp;p1)"
    1.52 +            "<pre>public&nbsp;void&nbsp;methodInheritedFromParent(int&nbsp;p1)"
    1.53          },
    1.54  
    1.55          //Make sure implemented interfaces from private superclass are inherited
    1.56          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicInterface.html",
    1.57 -            "<STRONG>All Known Implementing Classes:</STRONG></DT> <DD><A HREF=\"../pkg/PublicChild.html\" " +
    1.58 -            "title=\"class in pkg\">PublicChild</A>"},
    1.59 +            "<dl>" + NL + "<dt>All Known Implementing Classes:</dt>" + NL +
    1.60 +            "<dd><a href=\"../pkg/PublicChild.html\" title=\"class in pkg\">" +
    1.61 +            "PublicChild</a></dd>" + NL + "</dl>"},
    1.62  
    1.63          {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
    1.64 -            "<STRONG>All Implemented Interfaces:</STRONG></DT> <DD><A HREF=\"../pkg/PublicInterface.html\" " +
    1.65 -            "title=\"interface in pkg\">PublicInterface</A>"},
    1.66 +            "<dl>" + NL + "<dt>All Implemented Interfaces:</dt>" + NL +
    1.67 +            "<dd><a href=\"../pkg/PublicInterface.html\" title=\"interface in pkg\">" +
    1.68 +            "PublicInterface</a></dd>" + NL + "</dl>"},
    1.69  
    1.70          //Generic interface method test.
    1.71          {BUG_ID + "-1" + FS + "pkg2" + FS + "C.html",
    1.72 @@ -110,12 +110,12 @@
    1.73      private static final String[][] NEGATED_TEST1 = {
    1.74         // Should not document that a method overrides method from private class.
    1.75        {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
    1.76 -        "<STRONG>Overrides:</STRONG>"},
    1.77 +        "<strong>Overrides:</strong>"},
    1.78        // Should not document that a method specified by private interface.
    1.79        {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
    1.80 -        "<STRONG>Specified by:</STRONG>"},
    1.81 +        "<strong>Specified by:</strong>"},
    1.82        {BUG_ID + "-1" + FS + "pkg" + FS + "PublicInterface.html",
    1.83 -        "<STRONG>Specified by:</STRONG>"},
    1.84 +        "<strong>Specified by:</strong>"},
    1.85        // Should not mention that any documentation was copied.
    1.86        {BUG_ID + "-1" + FS + "pkg" + FS + "PublicChild.html",
    1.87          "Description copied from"},
    1.88 @@ -137,64 +137,64 @@
    1.89          //Do not inherit private interface method with generic parameters.
    1.90          //This method has been implemented.
    1.91          {BUG_ID + "-1" + FS + "pkg2" + FS + "C.html",
    1.92 -            "<STRONG><A HREF=\"../pkg2/I.html#hello(T)\">hello</A></STRONG>"},
    1.93 +            "<strong><a href=\"../pkg2/I.html#hello(T)\">hello</a></strong>"},
    1.94      };
    1.95  
    1.96      // Test output when -private flag is used.
    1.97      private static final String[][] TEST2 = {
    1.98          // Field inheritence from non-public superclass.
    1.99          {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.100 -            "Fields inherited from class " +
   1.101 -            "pkg.<A HREF=\"../pkg/PrivateParent.html\" " +
   1.102 -            "title=\"class in pkg\">PrivateParent</A>"
   1.103 +            "Fields inherited from class&nbsp;pkg." +
   1.104 +            "<a href=\"../pkg/PrivateParent.html\" title=\"class in pkg\">" +
   1.105 +            "PrivateParent</a>"
   1.106          },
   1.107          {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.108 -            "<A HREF=\"../pkg/PrivateParent.html#fieldInheritedFromParent\">" +
   1.109 -                "fieldInheritedFromParent</A>"
   1.110 +            "<a href=\"../pkg/PrivateParent.html#fieldInheritedFromParent\">" +
   1.111 +                "fieldInheritedFromParent</a>"
   1.112          },
   1.113          // Field inheritence from non-public superinterface.
   1.114          {BUG_ID + "-2" + FS + "pkg" + FS + "PublicInterface.html",
   1.115 -            "Fields inherited from interface " +
   1.116 -            "pkg.<A HREF=\"../pkg/PrivateInterface.html\" " +
   1.117 -            "title=\"interface in pkg\">PrivateInterface</A>"
   1.118 +            "Fields inherited from interface&nbsp;pkg." +
   1.119 +            "<a href=\"../pkg/PrivateInterface.html\" title=\"interface in pkg\">" +
   1.120 +            "PrivateInterface</a>"
   1.121          },
   1.122          {BUG_ID + "-2" + FS + "pkg" + FS + "PublicInterface.html",
   1.123 -            "<A HREF=\"../pkg/PrivateInterface.html#fieldInheritedFromInterface\">" +
   1.124 -                "fieldInheritedFromInterface</A>"
   1.125 +            "<a href=\"../pkg/PrivateInterface.html#fieldInheritedFromInterface\">" +
   1.126 +                "fieldInheritedFromInterface</a>"
   1.127          },
   1.128          // Method inheritence from non-public superclass.
   1.129          {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.130 -            "Methods inherited from class " +
   1.131 -            "pkg.<A HREF=\"../pkg/PrivateParent.html\" " +
   1.132 -            "title=\"class in pkg\">PrivateParent</A>"
   1.133 +            "Methods inherited from class&nbsp;pkg." +
   1.134 +            "<a href=\"../pkg/PrivateParent.html\" title=\"class in pkg\">" +
   1.135 +            "PrivateParent</a>"
   1.136          },
   1.137          {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.138 -            "<A HREF=\"../pkg/PrivateParent.html#methodInheritedFromParent(int)\">" +
   1.139 -                "methodInheritedFromParent</A>"
   1.140 +            "<a href=\"../pkg/PrivateParent.html#methodInheritedFromParent(int)\">" +
   1.141 +                "methodInheritedFromParent</a>"
   1.142          },
   1.143          // Should document that a method overrides method from private class.
   1.144         {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.145 -            "<STRONG>Overrides:</STRONG></DT><DD><CODE>" +
   1.146 -            "<A HREF=\"../pkg/PrivateParent.html#methodOverridenFromParent(char[], int, T, V, java.util.List)\">" +
   1.147 -            "methodOverridenFromParent</A></CODE> in class <CODE>" +
   1.148 -            "<A HREF=\"../pkg/PrivateParent.html\" title=\"class in pkg\">" +
   1.149 -            "PrivateParent</A></CODE></DD>" + NL + "</DL>"},
   1.150 +            "<dt><strong>Overrides:</strong></dt>" + NL +
   1.151 +            "<dd><code><a href=\"../pkg/PrivateParent.html#methodOverridenFromParent(char[], int, T, V, java.util.List)\">" +
   1.152 +            "methodOverridenFromParent</a></code>&nbsp;in class&nbsp;<code>" +
   1.153 +            "<a href=\"../pkg/PrivateParent.html\" title=\"class in pkg\">" +
   1.154 +            "PrivateParent</a></code></dd>"},
   1.155         // Should document that a method is specified by private interface.
   1.156         {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.157 -            "<STRONG>Specified by:</STRONG></DT><DD><CODE>" +
   1.158 -            "<A HREF=\"../pkg/PrivateInterface.html#methodInterface(int)\">" +
   1.159 -            "methodInterface</A></CODE> in interface <CODE>" +
   1.160 -            "<A HREF=\"../pkg/PrivateInterface.html\" title=\"interface in pkg\">" +
   1.161 -            "PrivateInterface</A></CODE></DD>" + NL + "</DL>" + NL + "</DD>"},
   1.162 +            "<dt><strong>Specified by:</strong></dt>" + NL +
   1.163 +            "<dd><code><a href=\"../pkg/PrivateInterface.html#methodInterface(int)\">" +
   1.164 +            "methodInterface</a></code>&nbsp;in interface&nbsp;<code>" +
   1.165 +            "<a href=\"../pkg/PrivateInterface.html\" title=\"interface in pkg\">" +
   1.166 +            "PrivateInterface</a></code></dd>"},
   1.167         // Method inheritence from non-public superinterface.
   1.168         {BUG_ID + "-2" + FS + "pkg" + FS + "PublicInterface.html",
   1.169 -            "Methods inherited from interface " +
   1.170 -            "pkg.<A HREF=\"../pkg/PrivateInterface.html\" " +
   1.171 -            "title=\"interface in pkg\">PrivateInterface</A>"
   1.172 +            "Methods inherited from interface&nbsp;pkg." +
   1.173 +            "<a href=\"../pkg/PrivateInterface.html\" title=\"interface in pkg\">" +
   1.174 +            "PrivateInterface</a>"
   1.175          },
   1.176          {BUG_ID + "-2" + FS + "pkg" + FS + "PrivateInterface.html",
   1.177 -            "<A HREF=\"../pkg/PrivateInterface.html#methodInterface(int)\">" +
   1.178 -                "methodInterface</A>"
   1.179 +            "<a href=\"../pkg/PrivateInterface.html#methodInterface(int)\">" +
   1.180 +                "methodInterface</a>"
   1.181          },
   1.182        // Should mention that any documentation was copied.
   1.183        {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.184 @@ -209,26 +209,31 @@
   1.185  
   1.186        //Make sure implemented interfaces from private superclass are inherited
   1.187        {BUG_ID + "-2" + FS + "pkg" + FS + "PublicInterface.html",
   1.188 -        "<STRONG>All Known Implementing Classes:</STRONG></DT> <DD><A HREF=\"../pkg/PrivateParent.html\" " +
   1.189 -        "title=\"class in pkg\">PrivateParent</A>, " +
   1.190 -        "<A HREF=\"../pkg/PublicChild.html\" title=\"class in pkg\">PublicChild</A>"},
   1.191 +        "<dl>" + NL + "<dt>All Known Implementing Classes:</dt>" + NL +
   1.192 +        "<dd><a href=\"../pkg/PrivateParent.html\" title=\"class in pkg\">" +
   1.193 +        "PrivateParent</a>, " +
   1.194 +        "<a href=\"../pkg/PublicChild.html\" title=\"class in pkg\">PublicChild" +
   1.195 +        "</a></dd>" + NL + "</dl>"},
   1.196  
   1.197        {BUG_ID + "-2" + FS + "pkg" + FS + "PublicChild.html",
   1.198 -        "<STRONG>All Implemented Interfaces:</STRONG></DT> <DD><A HREF=\"../pkg/PrivateInterface.html\" " +
   1.199 -        "title=\"interface in pkg\">PrivateInterface</A>, " +
   1.200 -        "<A HREF=\"../pkg/PublicInterface.html\" title=\"interface in pkg\">" +
   1.201 -        "PublicInterface</A>"},
   1.202 +        "<dl>" + NL + "<dt>All Implemented Interfaces:</dt>" + NL +
   1.203 +        "<dd><a href=\"../pkg/PrivateInterface.html\" title=\"interface in pkg\">" +
   1.204 +        "PrivateInterface</a>, " +
   1.205 +        "<a href=\"../pkg/PublicInterface.html\" title=\"interface in pkg\">" +
   1.206 +        "PublicInterface</a></dd>" + NL + "</dl>"},
   1.207  
   1.208        //Since private flag is used, we can document that private interface method
   1.209        //with generic parameters has been implemented.
   1.210        {BUG_ID + "-2" + FS + "pkg2" + FS + "C.html",
   1.211 -            "<STRONG>Description copied from interface: " +
   1.212 -            "<CODE><A HREF=\"../pkg2/I.html#hello(T)\">I</A></CODE></STRONG>"},
   1.213 +            "<strong>Description copied from interface:&nbsp;<code>" +
   1.214 +            "<a href=\"../pkg2/I.html#hello(T)\">I</a></code></strong>"},
   1.215  
   1.216        {BUG_ID + "-2" + FS + "pkg2" + FS + "C.html",
   1.217 -            "<STRONG>Specified by:</STRONG></DT><DD><CODE><A HREF=\"../pkg2/I.html#hello(T)\">" +
   1.218 -            "hello</A></CODE> in interface <CODE><A HREF=\"../pkg2/I.html\" " +
   1.219 -            "title=\"interface in pkg2\">I</A>"},
   1.220 +            "<dt><strong>Specified by:</strong></dt>" + NL +
   1.221 +            "<dd><code><a href=\"../pkg2/I.html#hello(T)\">hello</a></code>" +
   1.222 +            "&nbsp;in interface&nbsp;<code>" +
   1.223 +            "<a href=\"../pkg2/I.html\" title=\"interface in pkg2\">I</a>" +
   1.224 +            "&lt;java.lang.String&gt;</code></dd>"},
   1.225      };
   1.226      private static final String[][] NEGATED_TEST2 = NO_TEST;
   1.227  

mercurial