Author: steve.ebersole(a)jboss.com
Date: 2006-12-14 08:27:15 -0500 (Thu, 14 Dec 2006)
New Revision: 10992
Modified:
branches/Branch_3_2/Hibernate3/test/org/hibernate/junit/functional/FunctionalTestClassTestSuite.java
Log:
more tuning
Modified:
branches/Branch_3_2/Hibernate3/test/org/hibernate/junit/functional/FunctionalTestClassTestSuite.java
===================================================================
---
branches/Branch_3_2/Hibernate3/test/org/hibernate/junit/functional/FunctionalTestClassTestSuite.java 2006-12-14
13:27:05 UTC (rev 10991)
+++
branches/Branch_3_2/Hibernate3/test/org/hibernate/junit/functional/FunctionalTestClassTestSuite.java 2006-12-14
13:27:15 UTC (rev 10992)
@@ -49,6 +49,8 @@
settings = ( ExecutionEnvironment.Settings ) test;
// todo : we could also centralize the skipping of "database specific"
tests here
// instead of duplicating this notion in AllTests and
DatabaseSpecificFunctionalTestCase.
+ // as a test gets added, simply check to see if we should really add it via
+ // DatabaseSpecificFunctionalTestCase.appliesTo( ExecutionEnvironment.DIALECT )...
}
}
testCount++;
@@ -77,6 +79,7 @@
}
public void runTest(Test test, TestResult testResult) {
+ testPosition++;
if ( environmentSetupError != null ) {
testResult.startTest( test );
testResult.addError( test, environmentSetupError );
@@ -89,12 +92,10 @@
else {
FunctionalTestCase functionalTest = ( ( FunctionalTestCase ) test );
try {
- if ( ++testPosition < testCount ) {
- // disallow rebuilding the schema because this is the last test
- // in this suite, thus it is about to get dropped immediately
- // afterwards anyway...
- environment.setAllowRebuild( true );
- }
+ // disallow rebuilding the schema because this is the last test
+ // in this suite, thus it is about to get dropped immediately
+ // afterwards anyway...
+ environment.setAllowRebuild( testPosition < testCount );
functionalTest.setEnvironment( environment );
super.runTest( functionalTest, testResult );
}
Show replies by date