Class EUnitTestCase
- java.lang.Object
-
- org.eclipse.epsilon.workflow.test.WorkflowTestCase
-
- org.eclipse.epsilon.workflow.tasks.eunit.EUnitTestCase
-
- All Implemented Interfaces:
org.xml.sax.ErrorHandler
- Direct Known Subclasses:
EUnitBasicTests
,EUnitInlineModelTests
,EUnitModelComparisonTests
,EUnitWithEGLTests
,EUnitWithEVLTests
public abstract class EUnitTestCase extends WorkflowTestCase implements org.xml.sax.ErrorHandler
Abstract superclass for all EUnit test suites.- Author:
- Antonio Garcia-Dominguez
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.io.File
ANT_BUILD_FILE
protected static java.io.File
BASE_DIR
-
Constructor Summary
Constructors Constructor Description EUnitTestCase()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addTaskDefinitionsTo(org.apache.tools.ant.Project project)
protected void
checkOutput(java.io.File file, java.lang.String expectedPackage, java.lang.String[] expectedTestCases, java.util.Set<java.lang.String> expectedCasesWithFailures, java.util.Set<java.lang.String> expectedCasesWithErrors)
Checks that the JUnit-style XML reports are well-formed.void
cleanUp()
void
error(org.xml.sax.SAXParseException exception)
void
fatalError(org.xml.sax.SAXParseException exception)
void
warning(org.xml.sax.SAXParseException exception)
-
Methods inherited from class org.eclipse.epsilon.workflow.test.WorkflowTestCase
assertContains, runTarget
-
-
-
-
Method Detail
-
addTaskDefinitionsTo
protected void addTaskDefinitionsTo(org.apache.tools.ant.Project project)
- Specified by:
addTaskDefinitionsTo
in classWorkflowTestCase
-
cleanUp
public void cleanUp()
-
error
public void error(org.xml.sax.SAXParseException exception) throws org.xml.sax.SAXException
- Specified by:
error
in interfaceorg.xml.sax.ErrorHandler
- Throws:
org.xml.sax.SAXException
-
fatalError
public void fatalError(org.xml.sax.SAXParseException exception) throws org.xml.sax.SAXException
- Specified by:
fatalError
in interfaceorg.xml.sax.ErrorHandler
- Throws:
org.xml.sax.SAXException
-
warning
public void warning(org.xml.sax.SAXParseException exception) throws org.xml.sax.SAXException
- Specified by:
warning
in interfaceorg.xml.sax.ErrorHandler
- Throws:
org.xml.sax.SAXException
-
checkOutput
protected void checkOutput(java.io.File file, java.lang.String expectedPackage, java.lang.String[] expectedTestCases, java.util.Set<java.lang.String> expectedCasesWithFailures, java.util.Set<java.lang.String> expectedCasesWithErrors) throws org.xml.sax.SAXException, javax.xml.parsers.ParserConfigurationException, java.io.IOException
Checks that the JUnit-style XML reports are well-formed. There is no official schema for these, so we have defined our own schema for internal testing. We've based it on the Ant source code and this mailing list post.- Throws:
org.xml.sax.SAXException
- XML Schema could not be loaded, or the JUnit XML output could not be parsed or was invalid.javax.xml.parsers.ParserConfigurationException
- There was a problem while configuring the XML parser for the JUnit XML output.java.io.IOException
- There was a problem while reading from the specified path.
-
-