harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ndbe...@apache.org
Subject svn commit: r451801 [2/2] - in /incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common: javax/security/auth/ javax/security/auth/callback/ javax/security/auth/kerberos/ javax/security/auth/login/ javax/security/auth/x500/ javax/sec...
Date Sun, 01 Oct 2006 20:16:10 GMT
Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -87,14 +87,14 @@
         RealmCallback rCB;
         StringBuffer sb = new StringBuffer("");
         String ss;
-        for (int i = 0; i < prompts.length; i++) {
+        for (String element : prompts) {
             for (int j = 0; j < prompts.length; j++) {
-                rCB = new RealmCallback(prompts[i], defInfo[j]);
+                rCB = new RealmCallback(element, defInfo[j]);
                 assertEquals("Incoorect default info", rCB.getDefaultText(),
                         defInfo[j]);
-                assertEquals("Incorrect prompt", rCB.getPrompt(), prompts[i]);
+                assertEquals("Incorrect prompt", rCB.getPrompt(), element);
                 assertNull("Not null text", rCB.getText());
-                sb.replace(0, sb.length(), prompts[i]);
+                sb.replace(0, sb.length(), element);
                 sb.append(defInfo[j]);
                 ss = sb.toString();
                 rCB.setText(ss);
@@ -131,13 +131,13 @@
         RealmCallback rCB;
         StringBuffer sb = new StringBuffer("");
         String ss;
-        for (int i = 0; i < prompts.length; i++) {
-            rCB = new RealmCallback(prompts[i]);
+        for (String element : prompts) {
+            rCB = new RealmCallback(element);
             assertNull("Incoorect default info", rCB.getDefaultText());
-            assertEquals("Incorrect prompt", rCB.getPrompt(), prompts[i]);
+            assertEquals("Incorrect prompt", rCB.getPrompt(), element);
             assertNull("Not null text", rCB.getText());
-            sb = new StringBuffer(prompts[i]);
-            sb.replace(0, sb.length(), prompts[i]);
+            sb = new StringBuffer(element);
+            sb.replace(0, sb.length(), element);
             ss = sb.toString();
             rCB.setText(ss);
             assertEquals("Incorrect text", rCB.getText(), ss);

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmChoiceCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmChoiceCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmChoiceCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/RealmChoiceCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -119,9 +119,9 @@
      */ 
     public void test02() {
         RealmChoiceCallback rCCB;
-        for (int i = 0; i < prompts.length; i++) {
-            rCCB = new RealmChoiceCallback(prompts[i], choices, 0, false);
-            assertEquals("Incorrect prompt", rCCB.getPrompt(), prompts[i]);
+        for (String element : prompts) {
+            rCCB = new RealmChoiceCallback(element, choices, 0, false);
+            assertEquals("Incorrect prompt", rCCB.getPrompt(), element);
             String [] ch = rCCB.getChoices();
             assertEquals("Incorrect choices length", ch.length, choices.length);
             for (int j = 0; j < ch.length; j++) {
@@ -141,11 +141,11 @@
                 fail("UnsupportedOperationException should be thrown fot non-multiple callback");
             } catch (UnsupportedOperationException e) {
             }
-            for (int j = 0; j < indexes.length; j++) {
-                rCCB.setSelectedIndex(indexes[j]);
+            for (int element0 : indexes) {
+                rCCB.setSelectedIndex(element0);
                 ind = rCCB.getSelectedIndexes();
                 assertEquals("Incorrect index length", ind.length, 1);
-                assertEquals("Incorrect index", ind[0], indexes[j]);
+                assertEquals("Incorrect index", ind[0], element0);
             }
         }        
     }
@@ -159,9 +159,9 @@
      */ 
     public void test03() {
         RealmChoiceCallback rCCB;
-        for (int i = 0; i < prompts.length; i++) {
-            rCCB = new RealmChoiceCallback(prompts[i], choices, 0, true);
-            assertEquals("Incorrect prompt", rCCB.getPrompt(), prompts[i]);
+        for (String element : prompts) {
+            rCCB = new RealmChoiceCallback(element, choices, 0, true);
+            assertEquals("Incorrect prompt", rCCB.getPrompt(), element);
             String[] ch = rCCB.getChoices();
             assertEquals("Incorrect choices length", ch.length, choices.length);
             for (int j = 0; j < ch.length; j++) {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl1Test.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl1Test.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl1Test.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl1Test.java Sun Oct  1 13:16:07 2006
@@ -51,6 +51,7 @@
         super(arg0);
     }
 
+    @Override
     protected void setUp() throws Exception {
         super.setUp();
         if (!initProvs) {
@@ -58,12 +59,13 @@
             initProvs = true;
         }
         if (provs != null) {
-            for (int i = 0; i < provs.length; i++) {
-                Security.removeProvider(provs[i].getName());
+            for (Provider element : provs) {
+                Security.removeProvider(element.getName());
             }
         }
     }
     
+    @Override
     protected void tearDown() throws Exception {
         super.tearDown();
         if (provs != null) {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl2Test.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl2Test.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl2Test.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl2Test.java Sun Oct  1 13:16:07 2006
@@ -59,8 +59,8 @@
     protected void tearDown() throws Exception {
         super.tearDown();
         if (mProv != null) {
-            for (int i = 0; i < mProv.length; i++) {
-                Security.removeProvider(mProv[i].getName());
+            for (Provider element : mProv) {
+                Security.removeProvider(element.getName());
             }
         }
     }
@@ -75,8 +75,8 @@
     }
 
     private void addProviders() {
-        for (int i = 0; i < mProv.length; i++) {
-            Security.insertProviderAt(mProv[i], 2);
+        for (Provider element : mProv) {
+            Security.insertProviderAt(element, 2);
         }
     }
 
@@ -315,14 +315,14 @@
                 (new SpiEngUtils()).new MyProvider("MySaslServerProvider4",
                         "Testing provider SaslServerFactory - 4", SRVSSRV
                                 .concat(mech[0]), fServerClass02) };
-        for (int i = 0; i < mProv.length; i++) {
+        for (Provider element : mProv) {
             for (int j = 1; j < mech.length; j++) {
-                mProv[i].put(SRVSSRV.concat(mech[j]).concat(mech[j]),
+                element.put(SRVSSRV.concat(mech[j]).concat(mech[j]),
                         fServerClass02);
-                mProv[i].put(SRVSSRV.concat(mech[j]).concat(mech[j]),
+                element.put(SRVSSRV.concat(mech[j]).concat(mech[j]),
                         fServerClass01);
             }
-            mProv[i].put(SRVSSRV.concat(mech[0]).concat(mech[0]),
+            element.put(SRVSSRV.concat(mech[0]).concat(mech[0]),
                     fServerClass01);
         }
         addProviders();

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl3Test.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl3Test.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl3Test.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl3Test.java Sun Oct  1 13:16:07 2006
@@ -65,6 +65,7 @@
         super(arg0);
     }
 
+    @Override
     protected void setUp() throws Exception {
         super.setUp();
         if (!initProvs) {
@@ -72,8 +73,8 @@
             initProvs = true;
         }
         if (provs != null) {
-            for (int i = 0; i < provs.length; i++) {
-                Security.removeProvider(provs[i].getName());
+            for (Provider element : provs) {
+                Security.removeProvider(element.getName());
             }
         }
     }
@@ -81,19 +82,20 @@
     protected Provider[] mProv;
 
     private void addProviders() {
-        for (int i = 0; i < mProv.length; i++) {
-            Security.insertProviderAt(mProv[i], 1);
+        for (Provider element : mProv) {
+            Security.insertProviderAt(element, 1);
         }
     }
 
     /*
      * @see TestCase#tearDown()
      */
+    @Override
     protected void tearDown() throws Exception {
         super.tearDown();
         if (mProv != null) {
-            for (int i = 0; i < mProv.length; i++) {
-                Security.removeProvider(mProv[i].getName());
+            for (Provider element : mProv) {
+                Security.removeProvider(element.getName());
             }
         }
         if (provs != null) {
@@ -377,10 +379,12 @@
 }
 
 class mySaslClientFactoryExt extends mySaslClientFactory {
+    @Override
     public String[] getMechanismNames(Map prop) {
         return new String[] { "NAME-5", "NAME-6" };
     }
 
+    @Override
     public SaslClient createSaslClient(String[] mech, String id,
             String protocol, String srvName, Map prop, CallbackHandler hnd)
             throws SaslException {
@@ -397,17 +401,17 @@
 
     public void handle(Callback[] callbacks) throws IOException,
             UnsupportedCallbackException {
-        for (int i = 0; i < callbacks.length; i++) {
-            if (callbacks[i] instanceof NameCallback) {
-                NameCallback nc = (NameCallback) callbacks[i];
+        for (Callback element : callbacks) {
+            if (element instanceof NameCallback) {
+                NameCallback nc = (NameCallback) element;
                 nc.setName("Ok");
-            } else if (callbacks[i] instanceof PasswordCallback) {
-                PasswordCallback pc = (PasswordCallback) callbacks[i];
+            } else if (element instanceof PasswordCallback) {
+                PasswordCallback pc = (PasswordCallback) element;
                 System.err.print(pc.getPrompt());
                 System.err.flush();
                 pc.setPassword(new char[] { 'O', 'k' });
             } else {
-                throw new UnsupportedCallbackException(callbacks[i],
+                throw new UnsupportedCallbackException(element,
                         "Callback should be NamCallback or PasswordCallback");
             }
         }
@@ -420,15 +424,15 @@
 
     public void handle(Callback[] callbacks) throws IOException,
             UnsupportedCallbackException {
-        for (int i = 0; i < callbacks.length; i++) {
-            if (callbacks[i] instanceof TextOutputCallback) {
-                TextOutputCallback toc = (TextOutputCallback) callbacks[i];
+        for (Callback element : callbacks) {
+            if (element instanceof TextOutputCallback) {
+                TextOutputCallback toc = (TextOutputCallback) element;
                 if (toc.getMessageType() != TextOutputCallback.INFORMATION) {
                     throw new IOException("Unsupported message type: "
                             + toc.getMessageType());
                 }
             } else {
-                throw new UnsupportedCallbackException(callbacks[i],
+                throw new UnsupportedCallbackException(element,
                         "Callback should be TextOutputCallback");
             }
         }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl4Test.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl4Test.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl4Test.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/Sasl4Test.java Sun Oct  1 13:16:07 2006
@@ -63,6 +63,7 @@
         super(arg0);
     }
 
+    @Override
     protected void setUp() throws Exception {
         super.setUp();
         if (!initProvs) {
@@ -70,8 +71,8 @@
             initProvs = true;
         }
         if (provs != null) {
-            for (int i = 0; i < provs.length; i++) {
-                Security.removeProvider(provs[i].getName());
+            for (Provider element : provs) {
+                Security.removeProvider(element.getName());
             }
         }
     }
@@ -79,19 +80,20 @@
     protected Provider[] mProv;
 
     private void addProviders() {
-        for (int i = 0; i < mProv.length; i++) {
-            Security.insertProviderAt(mProv[i], 1);
+        for (Provider element : mProv) {
+            Security.insertProviderAt(element, 1);
         }
     }
 
     /*
      * @see TestCase#tearDown()
      */
+    @Override
     protected void tearDown() throws Exception {
         super.tearDown();
         if (mProv != null) {
-            for (int i = 0; i < mProv.length; i++) {
-                Security.removeProvider(mProv[i].getName());
+            for (Provider element : mProv) {
+                Security.removeProvider(element.getName());
             }
         }
         if (provs != null) {
@@ -375,10 +377,12 @@
 }
 
 class mySaslServerFactoryExt extends mySaslServerFactory {
+    @Override
     public String[] getMechanismNames(Map prop) {
         return new String[] { "MECH-5", "MECH-6" };
     }
 
+    @Override
     public SaslServer createSaslServer(String mech, String protocol,
             String srvName, Map prop, CallbackHandler hnd) throws SaslException {
         if (mech == null) {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/SaslExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/SaslExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/SaslExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/javax/security/sasl/SaslExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -84,10 +84,10 @@
      */
     public void testSaslException02() {
         SaslException tE;
-        for (int i = 0; i < msgs.length; i++) {
-            tE = new SaslException(msgs[i]);
-            assertEquals("getMessage() must return: ".concat(msgs[i]), tE
-                    .getMessage(), msgs[i]);
+        for (String element : msgs) {
+            tE = new SaslException(element);
+            assertEquals("getMessage() must return: ".concat(element), tE
+                    .getMessage(), element);
             assertNull("getCause() must return null", tE.getCause());
             try {
                 throw tE;
@@ -136,10 +136,10 @@
      */
     public void testSaslException05() {
         SaslException tE;
-        for (int i = 0; i < msgs.length; i++) {
-            tE = new SaslException(msgs[i], null);
-            assertEquals("getMessage() must return: ".concat(msgs[i]), tE
-                    .getMessage(), msgs[i]);
+        for (String element : msgs) {
+            tE = new SaslException(element, null);
+            assertEquals("getMessage() must return: ".concat(element), tE
+                    .getMessage(), element);
             assertNull("getCause() must return null", tE.getCause());
             try {
                 throw tE;
@@ -183,14 +183,14 @@
      */
     public void testSaslException07() {
         SaslException tE;
-        for (int i = 0; i < msgs.length; i++) {
-            tE = new SaslException(msgs[i], tCause);
+        for (String element : msgs) {
+            tE = new SaslException(element, tCause);
             String getM = tE.getMessage();
             String toS = tCause.toString();
-            if (msgs[i].length() > 0) {
-                assertTrue("getMessage() must contain ".concat(msgs[i]), getM
-                        .indexOf(msgs[i]) != -1);
-                if (!getM.equals(msgs[i])) {
+            if (element.length() > 0) {
+                assertTrue("getMessage() must contain ".concat(element), getM
+                        .indexOf(element) != -1);
+                if (!getM.equals(element)) {
                     assertTrue("getMessage() should contain ".concat(toS), getM
                             .indexOf(toS) != -1);
                 }
@@ -225,18 +225,18 @@
         SaslException eT;
         eT = new SaslException();
         assertNotNull("Incorrect null string", eT.toString());
-        for (int i = 0; i < msgs.length; i++) {
-            eT = new SaslException(msgs[i]);
+        for (String element : msgs) {
+            eT = new SaslException(element);
             assertTrue("Incorrect result string", eT.toString()
-                    .indexOf(msgs[i]) >= 0);
+                    .indexOf(element) >= 0);
 
-            for (int j = 0; j < th.length; j++) {
-                eT = new SaslException(msgs[i], th[j]);
+            for (Throwable element0 : th) {
+                eT = new SaslException(element, element0);
                 assertTrue("Incorrect result string", eT.toString().indexOf(
-                        msgs[i]) >= 0);
-                if (th[j] != null) {
+                        element) >= 0);
+                if (element0 != null) {
                     assertTrue("Incorrect result string", eT.toString()
-                            .indexOf(th[j].toString()) >= 0);
+                            .indexOf(element0.toString()) >= 0);
                 }
             }
         }
@@ -275,8 +275,8 @@
         Throwable eT1;
         eT = new SaslException();
 
-        for (int i = 0; i < msgs.length; i++) {
-            eT = new SaslException(msgs[i]);
+        for (String element : msgs) {
+            eT = new SaslException(element);
 
             for (int l = (thUpd.length - 1); l >= 0; l--) {
                 try {
@@ -307,21 +307,21 @@
         eT = new SaslException();
 
         boolean mod = false;
-        for (int i = 0; i < msgs.length; i++) {
-            for (int j = 0; j < th.length; j++) {
+        for (String element : msgs) {
+            for (Throwable element0 : th) {
                 mod = false;
-                for (int l = 0; l < thUpd.length; l++) {
-                    eT = new SaslException(msgs[i], th[j]);
+                for (Throwable element1 : thUpd) {
+                    eT = new SaslException(element, element0);
                     try {
-                        eT1 = eT.initCause(thUpd[l]);
+                        eT1 = eT.initCause(element1);
                         assertEquals(eT1, eT);
                         mod = true;
-                        if ((th[j] == null) && !mod) {
+                        if ((element0 == null) && !mod) {
                             assertEquals("Incorrect cause", eT.getCause(),
-                                    thUpd[l]);
+                                    element1);
                         }
                     } catch (IllegalStateException e) {
-                        if ((th[j] == null) && !mod) {
+                        if ((element0 == null) && !mod) {
                             fail("Unexpected exception: " + e);
                         }
                     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigParserTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigParserTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigParserTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigParserTest.java Sun Oct  1 13:16:07 2006
@@ -72,7 +72,8 @@
 		super(name);
 	}
 
-	public void setUp() throws Exception {
+	@Override
+    public void setUp() throws Exception {
 		p = System.getProperties();
 		File f = new File(fconf);
 		try {
@@ -169,8 +170,8 @@
 			byte[] b = str[i].getBytes();
 			OutputStream os = new FileOutputStream(file);
 
-			for (int j = 0; j < b.length; j++) {
-				os.write(b[j]);
+			for (byte element : b) {
+				os.write(element);
 			}
 
 			os.flush();

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigurationTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigurationTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigurationTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/login/DefaultConfigurationTest.java Sun Oct  1 13:16:07 2006
@@ -64,14 +64,16 @@
 	String oldp1 = null;
 	String oldp2 = null;
 
-	public void setUp() throws Exception {
+	@Override
+    public void setUp() throws Exception {
 		createConfFile();
 		
 		oldp1 = Security.getProperty("login.config.url.1");
 		oldp2 = Security.getProperty("login.config.url.2");
 	}
 
-	public void tearDown() throws Exception {
+	@Override
+    public void tearDown() throws Exception {
 		System.setSecurityManager(old);
 
 		TestUtils.setSystemProperty("login.config.url.1", oldp1);
@@ -114,14 +116,14 @@
 
 			ents = dc.getAppConfigurationEntry("Login1");
 			assertNotNull(ents);
-			for (int i = 0; i < ents.length; i++) {
+			for (AppConfigurationEntry element : ents) {
 				assertEquals("com.intel.security.auth.module.LoginModule1",
-						ents[i].getLoginModuleName());
+						element.getLoginModuleName());
 				m.clear();
 				m.put("debug1", "true");
 				m.put("test1", "false");
-				assertEquals(m, ents[i].getOptions());
-				assertEquals("LoginModuleControlFlag: required", ents[i]
+				assertEquals(m, element.getOptions());
+				assertEquals("LoginModuleControlFlag: required", element
 						.getControlFlag().toString());
 			}
 			
@@ -148,14 +150,14 @@
 		ents = dc.getAppConfigurationEntry("Login1");
 		assertNotNull(ents);
 		Map m = new HashMap();
-		for (int i = 0; i < ents.length; i++) {
+		for (AppConfigurationEntry element : ents) {
 			assertEquals("com.intel.security.auth.module.LoginModule1",
-					ents[i].getLoginModuleName());
+					element.getLoginModuleName());
 			m.clear();
 			m.put("debug1", "true");
 			m.put("test1", "false");
-			assertEquals(m, ents[i].getOptions());
-			assertEquals("LoginModuleControlFlag: required", ents[i]
+			assertEquals(m, element.getOptions());
+			assertEquals("LoginModuleControlFlag: required", element
 					.getControlFlag().toString());
 		}
 		
@@ -231,8 +233,8 @@
 		byte[] b = newConfFile.getBytes();
 
 		OutputStream os = new FileOutputStream(defaultConfFile);
-		for (int j = 0; j < b.length; j++) {
-			os.write(b[j]);
+		for (byte element : b) {
+			os.write(element);
 		}
 		os.flush();
 		os.close();
@@ -257,7 +259,8 @@
 			enableAccess = enable;
 		}
 
-		public void checkPermission(Permission p) {
+		@Override
+        public void checkPermission(Permission p) {
 			if (p instanceof AuthPermission && checkTarget.equals(p)) {
 				checkAsserted = true;
 				if (!enableAccess) {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ChoiceCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ChoiceCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ChoiceCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ChoiceCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -41,6 +41,7 @@
         junit.textui.TestRunner.run(ChoiceCallbackTest.class);
     }
 
+    @Override
     protected Object[] getData() {
 
         String prompt = "prompt";

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ConfirmationCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ConfirmationCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ConfirmationCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/ConfirmationCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
         junit.textui.TestRunner.run(ConfirmationCallbackTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] { new ConfirmationCallback("prompt",
                 ConfirmationCallback.INFORMATION,

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/LanguageCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/LanguageCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/LanguageCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/LanguageCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
         junit.textui.TestRunner.run(LanguageCallbackTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         LanguageCallback lc = new LanguageCallback();
         lc.setLocale(Locale.UK);

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/NameCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/NameCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/NameCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/NameCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
         junit.textui.TestRunner.run(NameCallbackTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         NameCallback nc = new NameCallback("prmpt", "defName");
         nc.setName("Name");

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/PasswordCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/PasswordCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/PasswordCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/PasswordCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
         junit.textui.TestRunner.run(PasswordCallbackTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         char[] pwd = {'a', 'b', 'c'};
         PasswordCallback p = new PasswordCallback("prmpt", true);

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextInputCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextInputCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextInputCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextInputCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
         junit.textui.TestRunner.run(TextInputCallbackTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         TextInputCallback t = new TextInputCallback("prmpt","defText");
         t.setText("new text");

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextOutputCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextOutputCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextOutputCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/TextOutputCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
         junit.textui.TestRunner.run(TextOutputCallbackTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] { new TextOutputCallback(
                 TextOutputCallback.INFORMATION, "message") };

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/UnsupportedCallbackExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/UnsupportedCallbackExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/UnsupportedCallbackExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/callback/serialization/UnsupportedCallbackExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
         junit.textui.TestRunner.run(UnsupportedCallbackExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new UnsupportedCallbackException(nc)};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/DelegationPermissionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/DelegationPermissionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/DelegationPermissionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/DelegationPermissionTest.java Sun Oct  1 13:16:07 2006
@@ -33,6 +33,7 @@
  */
 public class DelegationPermissionTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
         return new Object[] {
                 new DelegationPermission("\"AAA\" \"BBB\"", "action"),

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbDelegationPermissionCollectionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbDelegationPermissionCollectionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbDelegationPermissionCollectionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbDelegationPermissionCollectionTest.java Sun Oct  1 13:16:07 2006
@@ -24,10 +24,6 @@
 
 import java.security.Permission;
 import java.security.PermissionCollection;
-import java.util.Collection;
-import java.util.Enumeration;
-import java.util.HashSet;
-
 import javax.security.auth.kerberos.DelegationPermission;
 
 import org.apache.harmony.testframework.serialization.SerializationTest;
@@ -39,6 +35,7 @@
  */
 public class KrbDelegationPermissionCollectionTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
         Permission p1 = new DelegationPermission("\"AAA\" \"BBB\"", "action");
         Permission p2 = new DelegationPermission("\"AAA\" \"CCC\"");

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbServicePermissionCollectionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbServicePermissionCollectionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbServicePermissionCollectionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/KrbServicePermissionCollectionTest.java Sun Oct  1 13:16:07 2006
@@ -24,10 +24,6 @@
 
 import java.security.Permission;
 import java.security.PermissionCollection;
-import java.util.Collection;
-import java.util.Enumeration;
-import java.util.HashSet;
-
 import javax.security.auth.kerberos.ServicePermission;
 
 import org.apache.harmony.testframework.serialization.SerializationTest;
@@ -37,6 +33,7 @@
  */
 public class KrbServicePermissionCollectionTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
         Permission p1 = new ServicePermission("AAA", "accept");
         Permission p2 = new ServicePermission("BBB", "initiate");

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/ServicePermissionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/ServicePermissionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/ServicePermissionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/kerberos/serialization/ServicePermissionTest.java Sun Oct  1 13:16:07 2006
@@ -32,6 +32,7 @@
  */
 public class ServicePermissionTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
         return new Object[] { new ServicePermission("AAA", "accept"),
                 new ServicePermission("BBB", "initiate"),

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/LoginContextTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/LoginContextTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/LoginContextTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/LoginContextTest.java Sun Oct  1 13:16:07 2006
@@ -54,9 +54,11 @@
     }    
     static class MyConfig extends Configuration{
         AppConfigurationEntry[] entries = new AppConfigurationEntry[]{new AppConfigurationEntry(MyModule.class.getName(), LoginModuleControlFlag.REQUIRED, new HashMap())};
+        @Override
         public AppConfigurationEntry[] getAppConfigurationEntry(String name) {
             return entries;
         }
+        @Override
         public void refresh() {
         }
     }
@@ -86,6 +88,7 @@
         public String getName() {
             return name;
         }
+        @Override
         public String toString(){
             return name; 
         }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -38,6 +38,7 @@
         junit.textui.TestRunner.run(AccountExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new AccountException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExpiredExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExpiredExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExpiredExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountExpiredExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -36,6 +36,7 @@
         junit.textui.TestRunner.run(AccountExpiredExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new AccountExpiredException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountLockedExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountLockedExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountLockedExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountLockedExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -38,6 +38,7 @@
         junit.textui.TestRunner.run(AccountLockedExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new AccountLockedException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountNotFoundExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountNotFoundExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountNotFoundExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/AccountNotFoundExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
         junit.textui.TestRunner.run(AccountNotFoundExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new AccountNotFoundException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -38,6 +38,7 @@
         junit.textui.TestRunner.run(CredentialExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new CredentialException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExpiredExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExpiredExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExpiredExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialExpiredExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
         junit.textui.TestRunner.run(CredentialExpiredExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new CredentialExpiredException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialNotFoundExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialNotFoundExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialNotFoundExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/CredentialNotFoundExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
         junit.textui.TestRunner.run(CredentialNotFoundExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new CredentialNotFoundException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/FailedLoginExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/FailedLoginExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/FailedLoginExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/FailedLoginExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
         junit.textui.TestRunner.run(FailedLoginExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new FailedLoginException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/LoginExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/LoginExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/LoginExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/login/serialization/LoginExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
         junit.textui.TestRunner.run(LoginExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new LoginException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/AuthPermissionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/AuthPermissionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/AuthPermissionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/AuthPermissionTest.java Sun Oct  1 13:16:07 2006
@@ -33,6 +33,7 @@
 
 public class AuthPermissionTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new AuthPermission("name", "read")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/DestroyFailedExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/DestroyFailedExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/DestroyFailedExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/DestroyFailedExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
         junit.textui.TestRunner.run(DestroyFailedExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new DestroyFailedException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/PrivateCredentialPermissionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/PrivateCredentialPermissionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/PrivateCredentialPermissionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/PrivateCredentialPermissionTest.java Sun Oct  1 13:16:07 2006
@@ -33,6 +33,7 @@
 
 public class PrivateCredentialPermissionTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new PrivateCredentialPermission("a.b.Cred a.c.Princ \"duke\"", "read")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/RefreshFailedExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/RefreshFailedExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/RefreshFailedExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/RefreshFailedExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -38,6 +38,7 @@
         junit.textui.TestRunner.run(RefreshFailedExceptionTest.class);
     }
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new RefreshFailedException("message")};
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/SubjectTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/SubjectTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/SubjectTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/serialization/SubjectTest.java Sun Oct  1 13:16:07 2006
@@ -33,6 +33,7 @@
 
 public class SubjectTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
 
         Subject subject = new Subject();

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/x500/serialization/X500PrincipalTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/x500/serialization/X500PrincipalTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/x500/serialization/X500PrincipalTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/auth/x500/serialization/X500PrincipalTest.java Sun Oct  1 13:16:07 2006
@@ -32,6 +32,7 @@
  */
 public class X500PrincipalTest extends SerializationTest {
 
+    @Override
     protected Object[] getData() {
         return new Object[] {new X500Principal("CN=A"),
                 new X500Principal("CN=A, C=B"),

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthenticationExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthenticationExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthenticationExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthenticationExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
             "New message",
             "Long message for Exception. Long message for Exception. Long message for Exception." };
 
+    @Override
     protected Object[] getData() {
         String msg = null;
         Exception cause = new Exception(msgs[1]);

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthorizeCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthorizeCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthorizeCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/AuthorizeCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -40,6 +40,7 @@
             "New String",
             "Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID. Long stringID." };
 
+    @Override
     protected Object[] getData() {
         String msg = null;
         return new Object[] { new AuthorizeCallback(msg, msg),

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -42,14 +42,15 @@
 
     public static String addText = "This text was set to RealmCallback";
     
+    @Override
     protected Object[] getData() {
         Object [] oo = {
                 new RealmCallback(msgs[0], msgs[1]),
                 new RealmCallback(msgs[1], msgs[0]),
                 new RealmCallback(msgs[1], msgs[1])
         };
-        for (int i = 0; i < oo.length; i++) {
-            ((RealmCallback)oo[i]).setText(addText);
+        for (Object element : oo) {
+            ((RealmCallback)element).setText(addText);
         }
         return oo;
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmChoiceCallbackTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmChoiceCallbackTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmChoiceCallbackTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/RealmChoiceCallbackTest.java Sun Oct  1 13:16:07 2006
@@ -43,6 +43,7 @@
             "t"};
 
     public static final int [] idx = {2, 3};
+    @Override
     protected Object[] getData() {
         Object [] oo = {
                 new RealmChoiceCallback(msgs[0], msgs, 0, true),
@@ -51,9 +52,8 @@
                 new RealmChoiceCallback(msgs[2], msgs, 0, false)
 
         };        
-//       
-        for (int i = 0; i < oo.length; i++) {
-            RealmChoiceCallback rc = (RealmChoiceCallback)oo[i];           
+for (Object element : oo) {
+            RealmChoiceCallback rc = (RealmChoiceCallback)element;           
             if (rc.allowMultipleSelections()) {
                 rc.setSelectedIndexes(idx);
             } else {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/SaslExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/SaslExceptionTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/SaslExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/javax/security/sasl/serialization/SaslExceptionTest.java Sun Oct  1 13:16:07 2006
@@ -37,6 +37,7 @@
             "New message",
             "Long message for Exception. Long message for Exception. Long message for Exception." };
 
+    @Override
     protected Object[] getData() {
         String msg = null;
         Exception cause = new Exception(msgs[1]);

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/module/Krb5LoginModuleTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/module/Krb5LoginModuleTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/module/Krb5LoginModuleTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/module/Krb5LoginModuleTest.java Sun Oct  1 13:16:07 2006
@@ -50,11 +50,12 @@
     private KrbServer server;
 
     // module options
-    private TreeMap<String, String> options = new TreeMap<String, String>();
+    private final TreeMap<String, String> options = new TreeMap<String, String>();
 
     /**
      * Sets system env. properties and optionaly starts local mock server
      */
+    @Override
     protected void setUp() throws Exception {
 
         // save old system properties
@@ -79,6 +80,7 @@
     /**
      * Shuts down local server and restore system env. properties
      */
+    @Override
     protected void tearDown() throws Exception {
         if (server != null) {
             // shut down local server
@@ -167,6 +169,7 @@
 
         public byte[] respond;
 
+        @Override
         public void run() {
 
             try {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/support/SecurityChecker.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/support/SecurityChecker.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/support/SecurityChecker.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/apache/harmony/auth/tests/support/SecurityChecker.java Sun Oct  1 13:16:07 2006
@@ -42,6 +42,7 @@
         enableAccess = enable;
     }
 
+    @Override
     public void checkPermission(Permission p) {
         if (checkTarget.equals(p)) {
             checkAsserted = true;

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/GSSManagerTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/GSSManagerTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/GSSManagerTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/GSSManagerTest.java Sun Oct  1 13:16:07 2006
@@ -80,73 +80,88 @@
 
     public static class TestManager extends GSSManager {
 
+        @Override
         public void addProviderAtEnd(Provider p, Oid mech) throws GSSException {
         }
 
+        @Override
         public void addProviderAtFront(Provider p, Oid mech)
             throws GSSException {
         }
 
+        @Override
         public GSSContext createContext(byte[] interProcessToken)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSContext createContext(GSSCredential myCred)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSContext createContext(GSSName peer, Oid mech,
                                         GSSCredential myCred, int lifetime)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSCredential createCredential(GSSName name, int lifetime,
                                               Oid mech, int usage)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSCredential createCredential(GSSName name, int lifetime,
                                               Oid[] mechs, int usage)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSCredential createCredential(int usage) throws GSSException {
             return null;
         }
 
+        @Override
         public GSSName createName(byte[] name, Oid nameType, Oid mech)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSName createName(byte[] name, Oid nameType)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSName createName(String nameStr, Oid nameType, Oid mech)
             throws GSSException {
             return null;
         }
 
+        @Override
         public GSSName createName(String nameStr, Oid nameType)
             throws GSSException {
             return null;
         }
 
+        @Override
         public Oid[] getMechs() {
             return null;
         }
 
+        @Override
         public Oid[] getMechsForName(Oid nameType) {
             return null;
         }
 
+        @Override
         public Oid[] getNamesForMech(Oid mech) throws GSSException {
             return null;
         }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/OidTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/OidTest.java?view=diff&rev=451801&r1=451800&r2=451801
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/OidTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/auth/src/test/java/common/org/ietf/jgss/OidTest.java Sun Oct  1 13:16:07 2006
@@ -167,10 +167,10 @@
                 "2.2.-1", // negative third subidentifier
         };
 
-        for (int i = 0; i < testcase.length; i++) {
+        for (String element : testcase) {
             try {
-                new Oid(testcase[i]);
-                fail("No expected GSSException for oid string: " + testcase[i]);
+                new Oid(element);
+                fail("No expected GSSException for oid string: " + element);
             } catch (GSSException e) {
                 assertEquals(GSSException.FAILURE, e.getMajor());
                 assertEquals(0, e.getMinor());



Mime
View raw message