//************************************************************************** // // // National Institute Of Standards and Technology // DTS Version 1.1 // // HTMLHMetaElement Interface //************************************************************************** function HTMLMetaElement() { var tests = new Array (HTML0001HMTE(),HTML0002HMTE(),HTML0003HMTE(),HTML0004HMTE()); return tests; } //------------------------ test case HTML-0001HMTE ------------------------- // // Testing feature - The "content" attribute specifies associated // information. // // Testing approach - Retrieve the "content" attribute from the first // META element of the testing document and examine its // value. It should be equal to "Carmelo Montanez". // // Semantic Requirements: 1 // // Last modification date - August 24, 1999 // // Written by: Carmelo Montanez //---------------------------------------------------------------------------- function HTML0001HMTE() { var computedValue = ""; var expectedValue = "CARMELO MONTANEZ"; var results = ""; var testNode = ""; results = new testResults("HTML0001HMTE"); results.description = "The \"content\" attribute specifies associated "+ "information."; // // Retrieve targeted data. // testNode = new HTMLNodeObject(META); // // and access its "content" attribute. // computedValue = testNode.node.content; computedValue = computedValue.toUpperCase(); // // Write out results // results.expected = expectedValue; results.actual = computedValue; return results; } //------------------------ End test case HTML-0001HMTE ------------------------- // //------------------------ test case HTML-0002HMTE ------------------------- // // Testing feature - The "httpEquiv" attribute specifies an HTTP response // header name. // // Testing approach - Retrieve the "httpEquiv" attribute from the second // META element of the testing document and examine its // value. It should be equal to "Content-Type". // // Semantic Requirements: 2 // // Last modification date - August 24, 1999 // // Written by: Carmelo Montanez //---------------------------------------------------------------------------- function HTML0002HMTE() { var computedValue = ""; var expectedValue = "CONTENT-TYPE"; var results = ""; var testNode = ""; results = new testResults("HTML0002HMTE"); results.description = "The \"httpEquiv\" attribute specifies an HTTP "+ "response header name."; // // Retrieve targeted data. // testNode = new HTMLNodeObject(META,SECOND); // // and access its "httpEquiv" attribute. // computedValue = testNode.node.httpEquiv; computedValue = computedValue.toUpperCase(); // // Write out results // results.expected = expectedValue; results.actual = computedValue; return results; } //------------------------ End test case HTML-0002HMTE ------------------------- // //------------------------ test case HTML-0003HMTE ------------------------- // // Testing feature - The "name" attribute specifies the meta information // name. // // Testing approach - Retrieve the "name" attribute from the first // META element of the testing document and examine its // value. It should be equal to "Author". // // Semantic Requirements: 3 // // Last modification date - August 24, 1999 // // Written by: Carmelo Montanez //---------------------------------------------------------------------------- function HTML0003HMTE() { var computedValue = ""; var expectedValue = "AUTHOR"; var results = ""; var testNode = ""; results = new testResults("HTML0003HMTE"); results.description = "The \"name\" attribute specifies the meta "+ "information name."; // // Retrieve targeted data. // testNode = new HTMLNodeObject(META); // // and access its "name" attribute. // computedValue = testNode.node.name; computedValue = computedValue.toUpperCase(); // // Write out results // results.expected = expectedValue; results.actual = computedValue; return results; } //------------------------ End test case HTML-0003HMTE ------------------------- // //------------------------ test case HTML-0004HMTE ------------------------- // // Testing feature - The "scheme" attribute specifies a select form of content. // // Testing approach - Retrieve the "scheme" attribute from the first // META element of the testing document and examine its // value. It should be equal to "NIST Employee". // // Semantic Requirements: 4 // // Last modification date - August 24, 1999 // // Written by: Carmelo Montanez //---------------------------------------------------------------------------- function HTML0004HMTE() { var computedValue = ""; var expectedValue = "NIST EMPLOYEE"; var results = ""; var testNode = ""; results = new testResults("HTML0004HMTE"); results.description = "The \"scheme\" attribute specifies a select "+ "form of content."; // // Retrieve targeted data. // testNode = new HTMLNodeObject(META); // // and access its "scheme" attribute. // computedValue = testNode.node.scheme; computedValue = computedValue.toUpperCase(); // // Write out results // results.expected = expectedValue; results.actual = computedValue; return results; } //------------------------ End test case HTML-0004HMTE -------------------------