aboutsummaryrefslogtreecommitdiffstats
path: root/src/ooxml/testcases
diff options
context:
space:
mode:
authorDominik Stadler <centic@apache.org>2016-10-24 12:07:15 +0000
committerDominik Stadler <centic@apache.org>2016-10-24 12:07:15 +0000
commit18e02b061874eed18d56eb5e64a982a44395c6d0 (patch)
treefde1d10fbd8349903e0c2b572035e98288dc9694 /src/ooxml/testcases
parent49572b2ac87eccf4ce3f80d21c11fed67e63d198 (diff)
downloadpoi-18e02b061874eed18d56eb5e64a982a44395c6d0.tar.gz
poi-18e02b061874eed18d56eb5e64a982a44395c6d0.zip
Allow more time for a unit-test when running on slow Gump VM
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1766397 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/ooxml/testcases')
-rw-r--r--src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetMergeRegions.java12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetMergeRegions.java b/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetMergeRegions.java
index 88530dc033..fb7a9c0b01 100644
--- a/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetMergeRegions.java
+++ b/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetMergeRegions.java
@@ -41,9 +41,17 @@ public class TestXSSFSheetMergeRegions {
}
System.out.println("Retry " + i + " because run-time is too high: " + millis);
}
-
+
+ boolean inGump = false;
+ String version = System.getProperty("version.id");
+ if(version != null && version.startsWith("gump-")) {
+ inGump = true;
+ }
+
// This time is typically ~800ms, versus ~7800ms to iterate getMergedRegion(int).
- assertTrue("Should have taken <2000 ms to iterate 50k merged regions but took " + millis, millis < 2000);
+ // when running in Gump, the VM is very slow, so we should allow much more time
+ assertTrue("Should have taken <2000 ms to iterate 50k merged regions but took " + millis,
+ inGump ? millis < 8000 : millis < 2000);
} finally {
wb.close();
}