Keel 2.1RC2

org.apache.avalon.framework.configuration.test
Class DefaultConfigurationBuilderTestCase

java.lang.Object
  extended byjunit.framework.Assert
      extended byjunit.framework.TestCase
          extended byorg.apache.avalon.framework.configuration.test.DefaultConfigurationBuilderTestCase
All Implemented Interfaces:
junit.framework.Test

public final class DefaultConfigurationBuilderTestCase
extends junit.framework.TestCase

Test that the Configurations built by DefaultConfigurationBuilder meet the stated API contracts.

Author:
, ,

Field Summary
private  DefaultConfigurationBuilder m_builder
           
private  java.io.File m_file
           
private  DefaultConfigurationBuilder m_nsBuilder
           
private  java.io.File m_nsFile
           
private  java.lang.String m_nsFileName
           
private  java.lang.String m_path
           
private  java.lang.String m_simpleFileName
           
private  java.io.File m_testDirectory
           
private  java.lang.String mixedContentXML
           
private  java.lang.String nsXML
           
private  java.lang.String simpleXML
           
private  java.lang.String spaceTrimmingCheckXML
           
 
Fields inherited from class junit.framework.TestCase
 
Constructor Summary
DefaultConfigurationBuilderTestCase()
           
DefaultConfigurationBuilderTestCase(java.lang.String name)
           
 
Method Summary
private  void nsAssertions(Configuration conf)
          These assertions apply when the namespace-enabled builder is used to create a Configuration from nsXML, ie namespace support is enabled, and the XML uses namespaces.
protected  void setUp()
           
private  void simpleAssertions(Configuration conf)
          These assertions apply when the default builder is used to create a Configuration from simpleXML, ie namespace support is disabled.
private  void simpleAssertionsNS(Configuration conf)
          These assertions apply when the default builder is used to create a Configuration from nsXML, ie namespace support is disabled, but the XML uses namespaces.
protected  void tearDown()
           
 void testBuild()
           
 void testBuildFromFile()
           
 void testBuildFromFileName()
           
 void testMixedContentDetection()
           
 void testSpaceTrimming()
          Checks that whitespace is normally stripped but preserved if space preserving processing instructions are present.
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, name, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assert, assert, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertNotNull, assertNotNull, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

m_builder

private DefaultConfigurationBuilder m_builder

m_nsBuilder

private DefaultConfigurationBuilder m_nsBuilder

m_file

private java.io.File m_file

m_nsFile

private java.io.File m_nsFile

m_testDirectory

private java.io.File m_testDirectory

m_simpleFileName

private final java.lang.String m_simpleFileName
See Also:
Constant Field Values

m_nsFileName

private final java.lang.String m_nsFileName
See Also:
Constant Field Values

m_path

private final java.lang.String m_path
See Also:
Constant Field Values

simpleXML

private final java.lang.String simpleXML
See Also:
Constant Field Values

nsXML

private final java.lang.String nsXML
See Also:
Constant Field Values

spaceTrimmingCheckXML

private final java.lang.String spaceTrimmingCheckXML
See Also:
Constant Field Values

mixedContentXML

private final java.lang.String mixedContentXML
See Also:
Constant Field Values
Constructor Detail

DefaultConfigurationBuilderTestCase

public DefaultConfigurationBuilderTestCase()

DefaultConfigurationBuilderTestCase

public DefaultConfigurationBuilderTestCase(java.lang.String name)
Method Detail

simpleAssertions

private void simpleAssertions(Configuration conf)
                       throws ConfigurationException
These assertions apply when the default builder is used to create a Configuration from simpleXML, ie namespace support is disabled.

Throws:
ConfigurationException

simpleAssertionsNS

private void simpleAssertionsNS(Configuration conf)
                         throws ConfigurationException
These assertions apply when the default builder is used to create a Configuration from nsXML, ie namespace support is disabled, but the XML uses namespaces.

Throws:
ConfigurationException

nsAssertions

private void nsAssertions(Configuration conf)
                   throws ConfigurationException
These assertions apply when the namespace-enabled builder is used to create a Configuration from nsXML, ie namespace support is enabled, and the XML uses namespaces.

Throws:
ConfigurationException

setUp

protected void setUp()
              throws java.lang.Exception
Throws:
java.lang.Exception

tearDown

protected void tearDown()
                 throws java.lang.Exception
Throws:
java.lang.Exception

testBuildFromFileName

public void testBuildFromFileName()
                           throws java.lang.Exception
Throws:
java.lang.Exception

testBuildFromFile

public void testBuildFromFile()
                       throws java.lang.Exception
Throws:
java.lang.Exception

testBuild

public void testBuild()
               throws java.lang.Exception
Throws:
java.lang.Exception

testSpaceTrimming

public void testSpaceTrimming()
                       throws java.lang.Exception
Checks that whitespace is normally stripped but preserved if space preserving processing instructions are present.

Throws:
java.lang.Exception

testMixedContentDetection

public void testMixedContentDetection()
                               throws java.lang.Exception
Throws:
java.lang.Exception

Keel 2.1RC2

Please see keelframework.org for information about new Keel releases.