/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/*
* @test
* @bug 6786688
* @summary HTML tables should have table summary, caption and table headers.
* @author Bhavesh Patel
* @library ../lib/
* @build JavadocTester
* @build TestHtmlTableTags
* @run main TestHtmlTableTags
*/
//Test information.
//Javadoc arguments.
};
//Input for string tests for HTML table tags.
/*
* Test for validating summary for HTML tables
*/
//Package summary
"<table class=\"packageSummary\" border=\"0\" cellpadding=\"3\"" +
" cellspacing=\"0\" summary=\"Class Summary table, " +
"listing classes, and an explanation\">"
},
"<table class=\"packageSummary\" border=\"0\" cellpadding=\"3\"" +
" cellspacing=\"0\" summary=\"Interface Summary table, " +
"listing interfaces, and an explanation\">"
},
"<table class=\"packageSummary\" border=\"0\" cellpadding=\"3\"" +
" cellspacing=\"0\" summary=\"Enum Summary table, " +
"listing enums, and an explanation\">"
},
"<table class=\"packageSummary\" border=\"0\" cellpadding=\"3\"" +
" cellspacing=\"0\" summary=\"Annotation Types Summary table, " +
"listing annotation types, and an explanation\">"
},
// Class documentation
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Field Summary table, listing fields, " +
"and an explanation\">"
},
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Method Summary table, listing methods, " +
"and an explanation\">"
},
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Nested Class Summary table, listing " +
"nested classes, and an explanation\">"
},
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Constructor Summary table, listing " +
"constructors, and an explanation\">"
},
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Enum Constant Summary table, listing " +
"enum constants, and an explanation\">"
},
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Required Element Summary table, " +
"listing required elements, and an explanation\">"
},
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Optional Element Summary table, " +
"listing optional elements, and an explanation\">"
},
// Class use documentation
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing packages, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing fields, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing methods, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing fields, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing methods, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing packages, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing methods, and an explanation\">"
},
// Package use documentation
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing packages, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing classes, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing packages, and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" summary=\"Use " +
"table, listing classes, and an explanation\">"
},
// Deprecated
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" " +
"summary=\"Deprecated Fields table, listing deprecated fields, " +
"and an explanation\">"
},
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" " +
"summary=\"Deprecated Methods table, listing deprecated methods, " +
"and an explanation\">"
},
// Constant values
"<table border=\"0\" cellpadding=\"3\" cellspacing=\"0\" " +
"summary=\"Constant Field Values table, listing " +
"constant fields, and values\">"
},
// Overview Summary
"<table class=\"overviewSummary\" border=\"0\" cellpadding=\"3\" " +
"cellspacing=\"0\" summary=\"Packages table, " +
"listing packages, and an explanation\">"
},
/*
* Test for validating caption for HTML tables
*/
//Package summary
"<caption><span>Class Summary</span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Interface Summary</span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Enum Summary</span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Annotation Types Summary</span><span class=\"tabEnd\">" +
" </span></caption>"
},
// Class documentation
"<caption><span>Fields</span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Methods</span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Nested Classes</span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Constructors</span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Enum Constants</span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Required Elements</span><span class=\"tabEnd\"> " +
"</span></caption>"
},
"<caption><span>Optional Elements</span><span class=\"tabEnd\"> " +
"</span></caption>"
},
// Class use documentation
"title=\"interface in pkg1\">I1</a></span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Fields in <a href=\"../../pkg2/package-summary.html\">" +
"title=\"class in pkg1\">C1</a></span><span class=\"tabEnd\"> " +
"</span></caption>"
},
"<caption><span>Methods in <a href=\"../../pkg2/package-summary.html\">" +
"title=\"class in pkg1\">C1</a></span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Fields in <a href=\"../../pkg1/package-summary.html\">" +
"title=\"class in pkg2\">C2</a></span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Methods in <a href=\"../../pkg1/package-summary.html\">" +
"title=\"class in pkg2\">C2</a></span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Methods in <a href=\"../../pkg2/package-summary.html\">" +
"pkg2</a> that return <a href=\"../../pkg2/C2.ModalExclusionType.html\" " +
"title=\"enum in pkg2\">C2.ModalExclusionType</a></span>" +
"<span class=\"tabEnd\"> </span></caption>"
},
// Package use documentation
"<caption><span>Packages that use <a href=\"../pkg1/package-summary.html\">" +
"pkg1</a></span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Classes in <a href=\"../pkg1/package-summary.html\">" +
"pkg1</a> used by <a href=\"../pkg1/package-summary.html\">pkg1</a>" +
"</span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Packages that use <a href=\"../pkg2/package-summary.html\">" +
"pkg2</a></span><span class=\"tabEnd\"> </span></caption>"
},
"<caption><span>Classes in <a href=\"../pkg2/package-summary.html\">" +
"pkg2</a> used by <a href=\"../pkg1/package-summary.html\">pkg1</a>" +
"</span><span class=\"tabEnd\"> </span></caption>"
},
// Deprecated
"<caption><span>Deprecated Fields</span><span class=\"tabEnd\">" +
" </span></caption>"
},
"<caption><span>Deprecated Methods</span><span class=\"tabEnd\">" +
" </span></caption>"
},
// Constant values
"C1</a></span><span class=\"tabEnd\"> </span></caption>"
},
// Overview Summary
"<caption><span>Packages</span><span class=\"tabEnd\"> </span></caption>"
},
/*
* Test for validating headers for HTML tables
*/
//Package summary
"<th class=\"colFirst\" scope=\"col\">" +
">Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">" +
">Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">" +
">Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">" +
" scope=\"col\">Description</th>"
},
// Class documentation
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Field and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Method and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Class and Description</th>"
},
"<th class=\"colOne\" scope=\"col\">Constructor and Description</th>"
},
"<th class=\"colOne\" scope=\"col\">Enum Constant and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Required Element and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Optional Element and Description</th>"
},
// Class use documentation
"<th class=\"colFirst\" scope=\"col\">Package</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Field and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Method and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Field and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Method and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Package</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Method and Description</th>"
},
// Package use documentation
"<th class=\"colFirst\" scope=\"col\">Package</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Description</th>"
},
"<th class=\"colOne\" scope=\"col\">Class and Description</th>"
},
"<th class=\"colFirst\" scope=\"col\">Package</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Description</th>"
},
"<th class=\"colOne\" scope=\"col\">Class and Description</th>"
},
// Deprecated
"<th class=\"colOne\" scope=\"col\">Field and Description</th>"
},
"<th class=\"colOne\" scope=\"col\">Method and Description</th>"
},
// Constant values
"<th class=\"colFirst\" scope=\"col\">" +
" scope=\"col\">Constant Field</th>" + NL +
"<th class=\"colLast\" scope=\"col\">Value</th>"
},
// Overview Summary
"<th class=\"colFirst\" scope=\"col\">" +
">Description</th>"
}
};
/**
* The entry point of the test.
* @param args the array of command line arguments.
*/
}
/**
* {@inheritDoc}
*/
return BUG_ID;
}
/**
* {@inheritDoc}
*/
}
}