harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smish...@apache.org
Subject svn commit: r541575 - /harmony/enhanced/classlib/trunk/modules/security/src/test/api/java/org/apache/harmony/security/tests/java/security/Permissions2Test.java
Date Fri, 25 May 2007 07:47:17 GMT
Author: smishura
Date: Fri May 25 00:47:16 2007
New Revision: 541575

URL: http://svn.apache.org/viewvc?view=rev&rev=541575
Log:
Fix JUnit style

Modified:
    harmony/enhanced/classlib/trunk/modules/security/src/test/api/java/org/apache/harmony/security/tests/java/security/Permissions2Test.java

Modified: harmony/enhanced/classlib/trunk/modules/security/src/test/api/java/org/apache/harmony/security/tests/java/security/Permissions2Test.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/security/src/test/api/java/org/apache/harmony/security/tests/java/security/Permissions2Test.java?view=diff&rev=541575&r1=541574&r2=541575
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/security/src/test/api/java/org/apache/harmony/security/tests/java/security/Permissions2Test.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/security/src/test/api/java/org/apache/harmony/security/tests/java/security/Permissions2Test.java
Fri May 25 00:47:16 2007
@@ -40,12 +40,7 @@
 	 */
 	public void test_Constructor() {
 		// Test for method java.security.Permissions()
-		try {
-			new Permissions();
-		} catch (Exception e) {
-			fail("creating an instance of permissions constructor failed : "
-					+ e);
-		}
+        new Permissions();
 	}
 
 	/**
@@ -66,14 +61,9 @@
 		perm[5] = readInFile;
 		perm[6] = new FilePermission("hello.file", "write");
 		Permissions perms = new Permissions();
-		try {
-			for (int i = 0; i < perm.length; i++) {
-				perms.add(perm[i]);
-			}
-		} catch (IllegalStateException e) {
-			fail("add method failed with unexpected IllegalStateException : "
-					+ e);
-		}
+        for (int i = 0; i < perm.length; i++) {
+            perms.add(perm[i]);
+        }
 
 		Enumeration e = perms.elements();
 		FilePermission perm2[] = new FilePermission[10];



Mime
View raw message