Public Methods | |
| nodeappendchildgetnodename (DOMTestDocumentBuilderFactory factory) | |
| void | runTest () throws java.lang.Throwable |
| String | getTargetURI () |
Static Public Methods | |
| void | main (String[] args) |
Append a newly created node to the child list of the second employee and check the NodeName returned. The "getNodeName()" method should return "newChild".
Definition at line 45 of file nodeappendchildgetnodename.java.
|
|
Definition at line 47 of file nodeappendchildgetnodename.java.
00048 {
00049 super(factory);
00050
00051 }
|
|
|
Reimplemented from DOMTest. Definition at line 71 of file nodeappendchildgetnodename.java.
00071 {
00072 return "http://www.w3.org/2001/DOM-Test-Suite/level1/core/nodeappendchildgetnodename";
00073 }
|
|
|
Definition at line 74 of file nodeappendchildgetnodename.java. References DOMTestCase::doMain().
00074 {
00075 DOMTestCase.doMain(nodeappendchildgetnodename.class,args);
00076 }
|
|
|
Reimplemented from DOMTestCase. Definition at line 53 of file nodeappendchildgetnodename.java. References DOMTestCase::assertEquals(), and DOMTest::load().
00053 {
00054 Document doc;
00055 NodeList elementList;
00056 Node employeeNode;
00057 NodeList childList;
00058 Node newChild;
00059 Node appendNode;
00060 String childName;
00061 doc = load("staff");
00062 elementList = doc.getElementsByTagName("employee");
00063 employeeNode = elementList.item(1);
00064 childList = employeeNode.getChildNodes();
00065 newChild = doc.createElement("newChild");
00066 appendNode = employeeNode.appendChild(newChild);
00067 childName = appendNode.getNodeName();
00068 assertEquals("nodeAppendChildGetNodeNameAssert1","newChild",childName);
00069
00070 }
|
1.2.13.1 written by Dimitri van Heesch,
© 1997-2001