You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by ri...@apache.org on 2010/10/22 00:39:55 UTC

svn commit: r1026171 - /felix/sandbox/rickhall/bnd-test/org.apache.felix.test.framework.bootdelegation/src/org/apache/felix/test/framework/bootdelegation/BootDelegationTest.java

Author: rickhall
Date: Thu Oct 21 22:39:55 2010
New Revision: 1026171

URL: http://svn.apache.org/viewvc?rev=1026171&view=rev
Log:
Use fail().

Modified:
    felix/sandbox/rickhall/bnd-test/org.apache.felix.test.framework.bootdelegation/src/org/apache/felix/test/framework/bootdelegation/BootDelegationTest.java

Modified: felix/sandbox/rickhall/bnd-test/org.apache.felix.test.framework.bootdelegation/src/org/apache/felix/test/framework/bootdelegation/BootDelegationTest.java
URL: http://svn.apache.org/viewvc/felix/sandbox/rickhall/bnd-test/org.apache.felix.test.framework.bootdelegation/src/org/apache/felix/test/framework/bootdelegation/BootDelegationTest.java?rev=1026171&r1=1026170&r2=1026171&view=diff
==============================================================================
--- felix/sandbox/rickhall/bnd-test/org.apache.felix.test.framework.bootdelegation/src/org/apache/felix/test/framework/bootdelegation/BootDelegationTest.java (original)
+++ felix/sandbox/rickhall/bnd-test/org.apache.felix.test.framework.bootdelegation/src/org/apache/felix/test/framework/bootdelegation/BootDelegationTest.java Thu Oct 21 22:39:55 2010
@@ -119,7 +119,7 @@ public class BootDelegationTest extends 
         {
             Class clazz =
                 m_context.getBundle().loadClass("javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -136,7 +136,7 @@ public class BootDelegationTest extends 
         {
             Class clazz =
                 BundleLoader.loadClass(m_context.getBundle(), "javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -157,7 +157,7 @@ public class BootDelegationTest extends 
         }
         catch (ClassNotFoundException ex)
         {
-            assertTrue("Class load should have succeeded: " + ex, false);
+            fail("Class load should have succeeded: " + ex);
         }
 
         // Try to trigger implicit boot delegation under these conditions:
@@ -171,7 +171,7 @@ public class BootDelegationTest extends 
         {
             ClassLoader loader = new InternalClassLoader(false, m_context.getBundle());
             Class clazz = loader.loadClass("javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -190,7 +190,7 @@ public class BootDelegationTest extends 
             ClassLoader loader =
                 new InternalClassLoader(false, this.getClass().getClassLoader());
             Class clazz = loader.loadClass("javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -208,7 +208,7 @@ public class BootDelegationTest extends 
         {
             ClassLoader loader = new ExternalClassLoader(false, m_context.getBundle());
             Class clazz = loader.loadClass("javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -230,7 +230,7 @@ public class BootDelegationTest extends 
         }
         catch (ClassNotFoundException ex)
         {
-//            assertTrue("Class load should have succeeded: " + ex, false);
+            fail("Class load should have succeeded: " + ex);
         }
 
         // Try to trigger implicit boot delegation under these conditions:
@@ -246,7 +246,7 @@ public class BootDelegationTest extends 
             ClassLoader loader =
                 new InternalClassLoader(true, m_context.getBundle());
             Class clazz = loader.loadClass("javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -265,7 +265,7 @@ public class BootDelegationTest extends 
             ClassLoader loader =
                 new InternalClassLoader(true, this.getClass().getClassLoader());
             Class clazz = loader.loadClass("javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -284,7 +284,7 @@ public class BootDelegationTest extends 
             ClassLoader loader =
                 new ExternalClassLoader(true, m_context.getBundle());
             Class clazz = loader.loadClass("javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -306,7 +306,7 @@ public class BootDelegationTest extends 
         }
         catch (ClassNotFoundException ex)
         {
-//            assertTrue("Class load should have succeeded: " + ex, false);
+            fail("Class load should have succeeded: " + ex);
         }
 
         // Try to trigger implicit boot delegation under these conditions:
@@ -323,7 +323,7 @@ public class BootDelegationTest extends 
                 BundleLoader.loadClass(
                     new ExternalClassLoader(false, m_context.getBundle()),
                     "javax.management.Attribute");
-//            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -346,7 +346,7 @@ public class BootDelegationTest extends 
         }
         catch (ClassNotFoundException ex)
         {
-            assertTrue("Class load should have succeeded: " + ex, false);
+            fail("Class load should have succeeded: " + ex);
         }
 
         // Try to trigger implicit boot delegation under these conditions:
@@ -363,7 +363,7 @@ public class BootDelegationTest extends 
                 BundleLoader.loadClass(
                     new InternalClassLoader(false, m_context.getBundle()),
                     "javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -383,7 +383,7 @@ public class BootDelegationTest extends 
                 BundleLoader.loadClass(
                     new InternalClassLoader(false, this.getClass().getClassLoader()),
                     "javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -404,7 +404,7 @@ public class BootDelegationTest extends 
                 BundleLoader.loadClass(
                     new ExternalClassLoader(true, m_context.getBundle()),
                     "javax.management.Attribute");
-//            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -428,7 +428,7 @@ public class BootDelegationTest extends 
         }
         catch (ClassNotFoundException ex)
         {
-            assertTrue("Class load should have succeeded: " + ex, false);
+            fail("Class load should have succeeded: " + ex);
         }
 
         // Try to trigger implicit boot delegation under these conditions:
@@ -446,6 +446,7 @@ public class BootDelegationTest extends 
                 BundleLoader.loadClass(
                     new InternalClassLoader(true, m_context.getBundle()),
                     "javax.management.Attribute");
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {
@@ -466,7 +467,7 @@ public class BootDelegationTest extends 
                 BundleLoader.loadClass(
                     new InternalClassLoader(true, this.getClass().getClassLoader()),
                     "javax.management.Attribute");
-            assertTrue("Class load should have failed: " + clazz, false);
+            fail("Class load should have failed: " + clazz);
         }
         catch (ClassNotFoundException ex)
         {