harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From telli...@apache.org
Subject svn commit: r680952 - /harmony/enhanced/classlib/trunk/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/MulticastSocketTest.java
Date Wed, 30 Jul 2008 09:40:39 GMT
Author: tellison
Date: Wed Jul 30 02:40:37 2008
New Revision: 680952

URL: http://svn.apache.org/viewvc?rev=680952&view=rev
Log:
Fix bogus multicast socket constructor test.
Apparent misunderstanding of SO_REUSEADDR meaning.

Modified:
    harmony/enhanced/classlib/trunk/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/MulticastSocketTest.java

Modified: harmony/enhanced/classlib/trunk/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/MulticastSocketTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/MulticastSocketTest.java?rev=680952&r1=680951&r2=680952&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/MulticastSocketTest.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/MulticastSocketTest.java
Wed Jul 30 02:40:37 2008
@@ -142,13 +142,12 @@
 	/**
 	 * @tests java.net.MulticastSocket#MulticastSocket(int)
 	 */
-	public void test_ConstructorI() {
-		// Test for method java.net.MulticastSocket(int)
-		// Used in tests
+	public void test_ConstructorI() throws IOException {
+	    MulticastSocket orig = new MulticastSocket();
+        int port = orig.getLocalPort();
+        orig.close();
 		MulticastSocket dup = null;
 		try {
-			mss = new MulticastSocket();
-			int port = mss.getLocalPort();
 			dup = new MulticastSocket(port);
             // regression test for Harmony-1162
             assertTrue(dup.getReuseAddress());



Mime
View raw message