org.apache.commons.betwixt.scarab
Class TestScarabSettings

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.apache.commons.betwixt.xmlunit.XmlTestCase
              extended by org.apache.commons.betwixt.AbstractTestCase
                  extended by org.apache.commons.betwixt.scarab.TestScarabSettings
All Implemented Interfaces:
junit.framework.Test

public class TestScarabSettings
extends AbstractTestCase

Test harness which round trips a Scarab's settings xml file

Version:
$Id: TestScarabSettings.java 438373 2006-08-30 05:17:21Z bayard $
Author:
Jason van Zyl

Field Summary
 
Fields inherited from class org.apache.commons.betwixt.AbstractTestCase
basedir
 
Fields inherited from class org.apache.commons.betwixt.xmlunit.XmlTestCase
debug
 
Constructor Summary
TestScarabSettings(java.lang.String testName)
          Constructor for the TestScarabSettings object
 
Method Summary
protected  org.apache.commons.betwixt.io.BeanReader createBeanReader()
          Description of the Method
protected  org.apache.commons.betwixt.XMLIntrospector createXMLIntrospector()
          ### it would be really nice to move this somewhere shareable across Maven / Turbine projects.
static void main(java.lang.String[] args)
           
static junit.framework.Test suite()
          A unit test suite for JUnit
 void testRoundTrip()
          Tests we can round trip from the XML -> bean -> XML -> bean.
protected  void testScarabSettings(ScarabSettings ss)
          Tests the value of the Project object that has just been parsed
protected  void write(java.lang.Object bean, java.io.Writer out)
          Description of the Method
 
Methods inherited from class org.apache.commons.betwixt.AbstractTestCase
createBean, getTestFile, getTestFileURL
 
Methods inherited from class org.apache.commons.betwixt.xmlunit.XmlTestCase
createDocumentBuilder, getDomFactory, isValid, parseFile, parseString, parseString, validateWithSchema, xmlAssertIsomorphic, xmlAssertIsomorphic, xmlAssertIsomorphic, xmlAssertIsomorphic, xmlAssertIsomorphicContent, xmlAssertIsomorphicContent, xmlAssertIsomorphicContent, xmlAssertIsomorphicContent, xmlAssertIsValid, xmlAssertIsValid
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, 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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TestScarabSettings

public TestScarabSettings(java.lang.String testName)
Constructor for the TestScarabSettings object

Parameters:
testName -
Method Detail

main

public static void main(java.lang.String[] args)

suite

public static junit.framework.Test suite()
A unit test suite for JUnit


testRoundTrip

public void testRoundTrip()
                   throws java.lang.Exception
Tests we can round trip from the XML -> bean -> XML -> bean. Ideally this method should test both Project objects are identical

Throws:
java.lang.Exception

createBeanReader

protected org.apache.commons.betwixt.io.BeanReader createBeanReader()
                                                             throws java.lang.Exception
Description of the Method

Throws:
java.lang.Exception

createXMLIntrospector

protected org.apache.commons.betwixt.XMLIntrospector createXMLIntrospector()
### it would be really nice to move this somewhere shareable across Maven / Turbine projects. Maybe a static helper method - question is what to call it???


testScarabSettings

protected void testScarabSettings(ScarabSettings ss)
                           throws java.lang.Exception
Tests the value of the Project object that has just been parsed

Throws:
java.lang.Exception

write

protected void write(java.lang.Object bean,
                     java.io.Writer out)
              throws java.lang.Exception
Description of the Method

Throws:
java.lang.Exception


Copyright 2002-2008 The Apache Software Foundation. All Rights Reserved.