polygene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nic...@apache.org
Subject zest-qi4j git commit: Adding NoException assumption, which seems to be triggering Jenkins build problems.
Date Mon, 15 Jun 2015 03:07:34 GMT
Repository: zest-qi4j
Updated Branches:
  refs/heads/develop 72e375eb6 -> 4df3b9a5c


Adding NoException assumption, which seems to be triggering Jenkins build problems.


Project: http://git-wip-us.apache.org/repos/asf/zest-qi4j/repo
Commit: http://git-wip-us.apache.org/repos/asf/zest-qi4j/commit/4df3b9a5
Tree: http://git-wip-us.apache.org/repos/asf/zest-qi4j/tree/4df3b9a5
Diff: http://git-wip-us.apache.org/repos/asf/zest-qi4j/diff/4df3b9a5

Branch: refs/heads/develop
Commit: 4df3b9a5c430bf1ba1c80b84aa6732df5c8d4924
Parents: 72e375e
Author: Niclas Hedhman <niclas@hedhman.org>
Authored: Mon Jun 15 11:07:17 2015 +0800
Committer: Niclas Hedhman <niclas@hedhman.org>
Committed: Mon Jun 15 11:07:17 2015 +0800

----------------------------------------------------------------------
 .../src/main/java/org/qi4j/test/util/Assume.java     | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zest-qi4j/blob/4df3b9a5/core/testsupport/src/main/java/org/qi4j/test/util/Assume.java
----------------------------------------------------------------------
diff --git a/core/testsupport/src/main/java/org/qi4j/test/util/Assume.java b/core/testsupport/src/main/java/org/qi4j/test/util/Assume.java
index 8d7e491..f8b23e4 100644
--- a/core/testsupport/src/main/java/org/qi4j/test/util/Assume.java
+++ b/core/testsupport/src/main/java/org/qi4j/test/util/Assume.java
@@ -47,10 +47,17 @@ public class Assume
      */
     public static void assumeDisplayPresent()
     {
-        assumeFalse( GraphicsEnvironment.getLocalGraphicsEnvironment().isHeadlessInstance()
);
-        String display = System.getenv( "DISPLAY" );
-        assumeThat( display, is( notNullValue() ) );
-        assumeTrue( display.length() > 0 );
+        try
+        {
+            assumeFalse( GraphicsEnvironment.getLocalGraphicsEnvironment().isHeadlessInstance()
);
+            String display = System.getenv( "DISPLAY" );
+            assumeThat( display, is( notNullValue() ) );
+            assumeTrue( display.length() > 0 );
+        } catch( UnsatisfiedLinkError e )
+        {
+            // assuming that this is caused due to missing video subsystem, or similar
+            assumeNoException( "Grahics system is missing?", e );
+        }
     }
 
     /**


Mime
View raw message