org.apache.axiom.ts.om.element
Class TestGetDefaultNamespace2

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.apache.axiom.testutils.suite.TestCaseEx
              extended by org.apache.axiom.ts.AxiomTestCase
                  extended by org.apache.axiom.ts.om.element.TestGetDefaultNamespace2
All Implemented Interfaces:
junit.framework.Test

public class TestGetDefaultNamespace2
extends AxiomTestCase

Tests the behavior of OMElement.getDefaultNamespace() in the special case where the element has no namespace and was created as a child element of an element having a default namespace with a non empty namespace URI. In this case the element must have a namespace declaration that overrides the default namespace. Therefore OMElement.getDefaultNamespace() must return null.

This is a regression test for AXIOM-400.


Field Summary
 
Fields inherited from class org.apache.axiom.ts.AxiomTestCase
metaFactory, TEST_PARSER_CONFIGURATION
 
Constructor Summary
TestGetDefaultNamespace2(OMMetaFactory metaFactory)
           
 
Method Summary
protected  void runTest()
           
 
Methods inherited from class org.apache.axiom.ts.AxiomTestCase
assertConsumed, getChildrenCount, getNumberOfOccurrences
 
Methods inherited from class org.apache.axiom.testutils.suite.TestCaseEx
addTestProperty, getTestProperties
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, setName, setUp, tearDown, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TestGetDefaultNamespace2

public TestGetDefaultNamespace2(OMMetaFactory metaFactory)
Method Detail

runTest

protected void runTest()
                throws Throwable
Specified by:
runTest in class org.apache.axiom.testutils.suite.TestCaseEx
Throws:
Throwable


Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.