GOMAttributeImplTestpublic class GOMAttributeImplTest extends TestCase
Fields Summary |
---|
protected GOMAttributeImpl | gomAttribute |
Methods Summary |
---|
protected void | setUp()
gomAttribute = new GOMAttributeImpl("test", "test");
| public void | testGOMAttributeImplStringString()
GOMAttributeImpl impl = new GOMAttributeImpl("test", "test");
assertTrue(impl.hasDefaultNamespace());
assertTrue(impl.getLocalName().equals(impl.getTextValue()));
assertEquals("test", impl.getLocalName());
| public void | testGOMAttributeImplStringStringStringString()
GOMAttributeImpl impl = new GOMAttributeImpl("www.apache.org", "ap",
"test", "test");
assertFalse(impl.hasDefaultNamespace());
assertTrue(impl.getLocalName().equals(impl.getTextValue()));
assertEquals("test", impl.getLocalName());
assertEquals("www.apache.org", impl.getQname().getNamespaceURI());
assertEquals("ap", impl.getQname().getPrefix());
| public void | testGetQname()
QName qname = gomAttribute.getQname();
assertSame(qname, gomAttribute.getQname());
assertTrue(gomAttribute.hasDefaultNamespace());
gomAttribute.setNamespaceUri("something else");
assertNotSame(qname, gomAttribute.getQname());
assertFalse(gomAttribute.hasDefaultNamespace());
|
|