public void testSetPrefix1() throws Throwable {
  Document doc;
  DocumentFragment docFragment;
  Element element;
  String elementTagName;
  String elementNodeName;
  doc=(Document)load("staff",builder);
  docFragment=doc.createDocumentFragment();
  element=doc.createElementNS("http://www.w3.org/DOM/Test","emp:address");
  docFragment.appendChild(element);
  element.setPrefix("dmstc");
  elementTagName=element.getTagName();
  elementNodeName=element.getNodeName();
  assertEquals("nodesetprefix01_tagname","dmstc:address",elementTagName);
  assertEquals("nodesetprefix01_nodeName","dmstc:address",elementNodeName);
}

public void testSetPrefix1 ( ) throws Throwable { Document doc ; DocumentFragment docFragment ; Element element ; String elementTagName ; String elementNodeName ; doc = ( Document ) load ( "staff" , builder ) ; docFragment = doc . createDocumentFragment ( ) ; element = doc . createElementNS ( "http://www.w3.org/DOM/Test" , "emp:address" ) ; docFragment . appendChild ( element ) ; element . setPrefix ( "dmstc" ) ; elementTagName = element . getTagName ( ) ; elementNodeName = element . getNodeName ( ) ; assertEquals ( "nodesetprefix01_tagname" , "dmstc:address" , elementTagName ) ; assertEquals ( "nodesetprefix01_nodeName" , "dmstc:address" , elementNodeName ) ; }
runs the test case .
