org.testng.Assert



API Populatity

35 Client projects

Project: org.testng

Project orientechnologies/orientdb in file ...speed.LocalCreateDocumentMultiThreadSpeedTest.java (2014-11-18)
@@ -25,7 +25,6 @@ import com.orientechnologies.orient.core.serialization.serializer.record.binary.
 import com.orientechnologies.orient.core.tx.OTransaction.TXTYPE;
 import com.orientechnologies.orient.test.database.base.OrientMultiThreadTest;
 import com.orientechnologies.orient.test.database.base.OrientThreadTest;
-import org.testng.Assert;
 import org.testng.annotations.Test;
 
 import java.util.Date;
@@ -88,6 +87,7 @@ public class LocalCreateDocumentMultiThreadSpeedTest extends OrientMultiThreadTe
     OGlobalConfiguration.USE_WAL.setValue(false);
     LocalCreateDocumentMultiThreadSpeedTest test = new LocalCreateDocumentMultiThreadSpeedTest();
     test.data.go(test);
+    OGlobalConfiguration.USE_WAL.setValue(true);
   }
 
   @Override
Project mongodb/mongo-java-driver in file ...f5faf3/src.test.com.mongodb.SecondaryReadTest.java (2012-03-09)
@@ -20,7 +20,6 @@ package com.mongodb;
 
 import com.mongodb.util.TestCase;
 import org.bson.types.ObjectId;
-import org.testng.Assert;
 import org.testng.annotations.Test;
 
 import java.util.ArrayList;
@@ -283,7 +282,7 @@ public class SecondaryReadTest extends TestCase {
             } else {
                 deviation = (double)100 - (((double)queriesExecuted / (double)expectedPerSecondary) * (double)100);
             }
-            Assert.assertTrue(deviation <= MAX_DEVIATION_PERCENT, "Percentage deviation of " + deviation + " is higher than " + MAX_DEVIATION_PERCENT);
+            assertLess(deviation, MAX_DEVIATION_PERCENT);
         }
     }
 
Project jclouds/jclouds in file ...s.BindCDNPurgeEmailAddressesToHeadersMockTest.java (2014-03-03)
@@ -24,13 +24,12 @@ import org.jclouds.http.HttpRequest;
 import org.jclouds.openstack.v2_0.internal.BaseOpenStackMockTest;
 import org.jclouds.rackspace.cloudfiles.v1.CloudFilesApi;
 import org.jclouds.rackspace.cloudfiles.v1.reference.CloudFilesHeaders;
-import org.testng.Assert;
 import org.testng.annotations.Test;
 
 import com.google.common.collect.ImmutableList;
 
 /**
- * Tests behavior of {@code BindCDNPurgeEmailAddressesToHeaders}
+ * Tests the behavior of {@code BindCDNPurgeEmailAddressesToHeaders}.
  * 
  * @author Jeremy Daggett
  */
@@ -50,7 +49,7 @@ public class BindCDNPurgeEmailAddressesToHeadersMockTest extends BaseOpenStackMo
             .method("DELETE")
             .endpoint("https://storage101.dfw1.clouddrive.com/v1/MossoCloudFS_XXXXXX/")
             .addHeader(CloudFilesHeaders.CDN_PURGE_OBJECT_EMAIL, "foo@bar.com, bar@foo.com")
-            .build(); 
+            .build();
       
       assertEquals(actualRequest, expectedRequest);