mirror of
https://github.com/apache/openjpa.git
synced 2025-03-08 17:49:18 +00:00
OPENJPA-1616 Fix TestTimeoutException tests for Oracle and re-enable for DB2
git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@932139 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
92914c0a6d
commit
20a07726f9
@ -164,7 +164,7 @@
|
||||
</dictionary>
|
||||
|
||||
<dictionary class="org.apache.openjpa.jdbc.sql.OracleDictionary">
|
||||
<lock>42000,61000</lock>
|
||||
<lock>42000,61000,72000</lock>
|
||||
<referential-integrity>1,1400,1722,2291,2292</referential-integrity>
|
||||
<object-exists>23000</object-exists>
|
||||
<object-not-found></object-not-found>
|
||||
|
@ -1027,8 +1027,8 @@ public abstract class CacheTest extends AbstractTestCase {
|
||||
DataCache.NAME_DEFAULT, false);
|
||||
checkCache(cache, ids, new boolean[]{ true, true, true, true });
|
||||
|
||||
// should cause h to be dropped.
|
||||
Thread.currentThread().sleep(551);
|
||||
// should cause h to be dropped (timeout=500)
|
||||
Thread.currentThread().sleep(600);
|
||||
Thread.yield();
|
||||
checkCache(cache, ids, new boolean[]{ true, true, true, false });
|
||||
|
||||
@ -1039,8 +1039,8 @@ public abstract class CacheTest extends AbstractTestCase {
|
||||
boolean eStatus = !((((OpenJPAEntityManagerFactorySPI) factory)
|
||||
.getConfiguration()).getDataCacheTimeout() > 0);
|
||||
|
||||
// should cause f to be dropped.
|
||||
Thread.currentThread().sleep(550);
|
||||
// should cause f to be dropped (timeout=1000)
|
||||
Thread.currentThread().sleep(500);
|
||||
Thread.yield();
|
||||
checkCache(cache, ids,
|
||||
new boolean[]{ eStatus, false, true, false });
|
||||
@ -1051,8 +1051,8 @@ public abstract class CacheTest extends AbstractTestCase {
|
||||
assertInCache(q1, (eStatus) ? Boolean.TRUE : Boolean.FALSE);
|
||||
assertInCache(q2, Boolean.FALSE);
|
||||
|
||||
// should cause g to be dropped.
|
||||
Thread.currentThread().sleep(4050);
|
||||
// should cause g to be dropped (timeout=5000)
|
||||
Thread.currentThread().sleep(4000);
|
||||
Thread.yield();
|
||||
checkCache(cache, ids,
|
||||
new boolean[]{ eStatus, false, false, false });
|
||||
|
@ -44,7 +44,7 @@ public class TestTimeoutException extends SingleEMFTestCase {
|
||||
|
||||
public void setUp() {
|
||||
// TODO - Hack until OPENJPA-1594 is addressed
|
||||
setUnsupportedDatabases(OracleDictionary.class, DB2Dictionary.class);
|
||||
// setUnsupportedDatabases(OracleDictionary.class, DB2Dictionary.class);
|
||||
|
||||
// Disable tests for any DB that has supportsSelectForUpdate==false, like HSQLDictionary
|
||||
OpenJPAEntityManagerFactorySPI tempEMF = emf;
|
||||
|
Loading…
x
Reference in New Issue
Block a user