You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-commits@db.apache.org by ka...@apache.org on 2012/11/02 08:31:14 UTC
svn commit: r1404886 -
/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/AutomaticIndexStatisticsTest.java
Author: kahatlen
Date: Fri Nov 2 07:31:14 2012
New Revision: 1404886
URL: http://svn.apache.org/viewvc?rev=1404886&view=rev
Log:
DERBY-5964: Timestamp comparison failure in AutomaticIndexStatisticsTest.testStatisticsCorrectness
Run test in GMT timezone to prevent instabilities around transition
to or from DST.
Modified:
db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/AutomaticIndexStatisticsTest.java
Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/AutomaticIndexStatisticsTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/AutomaticIndexStatisticsTest.java?rev=1404886&r1=1404885&r2=1404886&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/AutomaticIndexStatisticsTest.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/AutomaticIndexStatisticsTest.java Fri Nov 2 07:31:14 2012
@@ -44,6 +44,7 @@ import org.apache.derbyTesting.junit.Ind
import org.apache.derbyTesting.junit.JDBC;
import org.apache.derbyTesting.junit.JDBCDataSource;
import org.apache.derbyTesting.junit.TestConfiguration;
+import org.apache.derbyTesting.junit.TimeZoneTestSetup;
import org.apache.derbyTesting.junit.Utilities;
/**
@@ -75,7 +76,14 @@ public class AutomaticIndexStatisticsTes
public static Test suite() {
TestSuite suite = new TestSuite(AutomaticIndexStatisticsTest.class);
- return TestConfiguration.additionalDatabaseDecorator(suite, MASTERDB);
+ // DERBY-5964: The test needs to check the timestamp stored in
+ // SYSSTATISTICS, which is in the local timezone. Since those
+ // timestamps may be ambiguous around the transition to or from DST,
+ // run this test in a timezone that doesn't observe DST. The
+ // TimeZoneTestSetup can probably be removed once DERBY-5974 is fixed.
+ return new TimeZoneTestSetup(
+ TestConfiguration.additionalDatabaseDecorator(suite, MASTERDB),
+ "GMT");
}
/** Initialize the default statistics helper object. */