brooklyn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aleds...@apache.org
Subject [1/2] incubator-brooklyn git commit: Mark tests in NetworkingUtilsTest as integration
Date Wed, 26 Nov 2014 11:07:40 GMT
Repository: incubator-brooklyn
Updated Branches:
  refs/heads/master a5db1546b -> c2f2396bd


Mark tests in NetworkingUtilsTest as integration

- For tests that open a port, mark them as integration because 
  failing on apache jenkins.

Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/b2012d76
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/b2012d76
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/b2012d76

Branch: refs/heads/master
Commit: b2012d765d2da7b76e94633b9f532d526ca3fc79
Parents: 0f50c58
Author: Aled Sage <aled.sage@gmail.com>
Authored: Wed Nov 26 10:55:16 2014 +0000
Committer: Aled Sage <aled.sage@gmail.com>
Committed: Wed Nov 26 10:55:16 2014 +0000

----------------------------------------------------------------------
 .../java/brooklyn/util/net/NetworkingUtilsTest.java     | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b2012d76/utils/common/src/test/java/brooklyn/util/net/NetworkingUtilsTest.java
----------------------------------------------------------------------
diff --git a/utils/common/src/test/java/brooklyn/util/net/NetworkingUtilsTest.java b/utils/common/src/test/java/brooklyn/util/net/NetworkingUtilsTest.java
index 6c693d1..a5623d9 100644
--- a/utils/common/src/test/java/brooklyn/util/net/NetworkingUtilsTest.java
+++ b/utils/common/src/test/java/brooklyn/util/net/NetworkingUtilsTest.java
@@ -107,8 +107,11 @@ public class NetworkingUtilsTest {
         if (numFree<=5)
             fail("This test requires that at least some ports near 58769+ not be in use.");
     }
-    
-    @Test
+
+    // Integration because fails in apache jenkins sometimes with "could not get a port".
+    // Could all the ports between 58767 and 60000 be in use (!) or is there a restriction
in
+    // the environment?
+    @Test(groups="Integration")
     public void testIsPortAvailableReportsFalseWhenPortIsInUse() throws Exception {
         int port = 58767;
         ServerSocket ss = null;
@@ -135,8 +138,9 @@ public class NetworkingUtilsTest {
                 assertTrue(Networking.isPortAvailable(portF), "port "+portF+" not made available
afterwards");
             }});
     }
-    
-    @Test
+
+    // See comment on {@link #testIsPortAvailableReportsFalseWhenPortIsInUse()} for why this
is integration.
+    @Test(groups="Integration")
     public void testIsPortAvailableReportsPromptly() throws Exception {
         // repeat until we can get an available port
         int port = 58767;


Mime
View raw message