ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akuznet...@apache.org
Subject [10/50] ignite git commit: Increased test timeout.
Date Wed, 09 Sep 2015 12:37:22 GMT
Increased test timeout.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/86f80372
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/86f80372
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/86f80372

Branch: refs/heads/ignite-843
Commit: 86f80372a23e502b58649b1e36c8a8a84f035318
Parents: c6d4b46
Author: sboikov <sboikov@gridgain.com>
Authored: Tue Sep 8 13:21:39 2015 +0300
Committer: sboikov <sboikov@gridgain.com>
Committed: Tue Sep 8 13:21:39 2015 +0300

----------------------------------------------------------------------
 .../ignite/internal/GridVersionSelfTest.java    | 20 +++++++++-----------
 1 file changed, 9 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/86f80372/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java
index d383ad6..4751a0c 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java
@@ -17,8 +17,9 @@
 
 package org.apache.ignite.internal;
 
-import org.apache.ignite.internal.util.typedef.internal.U;
+import org.apache.ignite.internal.util.lang.GridAbsPredicate;
 import org.apache.ignite.lang.IgniteProductVersion;
+import org.apache.ignite.testframework.GridTestUtils;
 import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest;
 
 import static org.apache.ignite.IgniteSystemProperties.IGNITE_UPDATE_NOTIFIER;
@@ -36,20 +37,17 @@ public class GridVersionSelfTest extends GridCommonAbstractTest {
         System.setProperty(IGNITE_UPDATE_NOTIFIER, "true");
 
         try {
-            IgniteEx ignite = (IgniteEx)startGrid();
+            final IgniteEx ignite = (IgniteEx)startGrid();
 
             IgniteProductVersion currVer = ignite.version();
 
-            String newVer = null;
+            GridTestUtils.waitForCondition(new GridAbsPredicate() {
+                @Override public boolean apply() {
+                    return ignite.latestVersion() != null;
+                }
+            }, 2 * 60_000);
 
-            for (int i = 0; i < 30; i++) {
-                newVer = ignite.latestVersion();
-
-                if (newVer != null)
-                    break;
-
-                U.sleep(100);
-            }
+            String newVer = ignite.latestVersion();
 
             info("Versions [cur=" + currVer + ", latest=" + newVer + ']');
 


Mime
View raw message