junit.framework.Assert



Project alibaba/druid in file ...d.sql.visitor.ParameterizedOutputVisitorUtils.java (2012-03-31)
@@ -2,8 +2,6 @@ package com.alibaba.druid.sql.visitor;
 
 import java.util.List;
 
-import junit.framework.Assert;
-
 import com.alibaba.druid.sql.ast.SQLExpr;
 import com.alibaba.druid.sql.ast.SQLStatement;
 import com.alibaba.druid.sql.ast.expr.SQLBinaryOpExpr;
@@ -27,8 +25,6 @@ public class ParameterizedOutputVisitorUtils {
         List<SQLStatement> statementList = parser.parseStatementList();
         SQLStatement statemen = statementList.get(0);
 
-        Assert.assertEquals(1, statementList.size());
-
         StringBuilder out = new StringBuilder();
         SQLASTOutputVisitor visitor = createParameterizedOutputVisitor(out, dbType);
         statemen.accept(visitor);
Project Activiti/Activiti in file ...g.activiti.standalone.history.FullHistoryTest.java (2013-05-19)
@@ -23,8 +23,6 @@ import java.util.Map;
 import javax.persistence.EntityManager;
 import javax.persistence.EntityManagerFactory;
 
-import junit.framework.Assert;
-
 import org.activiti.engine.ActivitiException;
 import org.activiti.engine.ActivitiIllegalArgumentException;
 import org.activiti.engine.history.HistoricActivityInstance;
@@ -915,7 +913,7 @@ public class FullHistoryTest extends ResourceActivitiTestCase {
     assertEquals(2, details.size());
     
     // Should have 2 different historic activity instance ID's, with the same activityId
-    Assert.assertNotSame(details.get(0).getActivityInstanceId(), details.get(1).getActivityInstanceId());
+    assertNotSame(details.get(0).getActivityInstanceId(), details.get(1).getActivityInstanceId());
     
     HistoricActivityInstance historicActInst1 = historyService.createHistoricActivityInstanceQuery()
       .activityInstanceId(details.get(0).getActivityInstanceId())
Project JetBrains/intellij-community in file ...5/platform.util.src.com.intellij.util.WaitFor.java (2009-09-01)
@@ -16,7 +16,6 @@
 package com.intellij.util;
 
 import org.jetbrains.annotations.NonNls;
-import junit.framework.Assert;
 
 
 /**
@@ -91,6 +90,6 @@ public abstract class WaitFor {
     assertCompleted("");
   }
   public void assertCompleted(String message) {
-    Assert.assertTrue(message, condition());
+    assert condition(): message;
   }
 }
Project JetBrains/intellij-community in file ...m.intellij.psi.impl.file.impl.FileManagerImpl.java (2009-09-01)
@@ -36,7 +36,6 @@ import com.intellij.util.containers.ConcurrentHashMap;
 import com.intellij.util.containers.ConcurrentWeakValueHashMap;
 import com.intellij.util.messages.MessageBusConnection;
 import gnu.trove.THashMap;
-import junit.framework.Assert;
 import org.jetbrains.annotations.NonNls;
 import org.jetbrains.annotations.NotNull;
 import org.jetbrains.annotations.Nullable;
@@ -270,7 +269,7 @@ public class FileManagerImpl implements FileManager {
       LOG.assertTrue(vFile.isValid());
       PsiFile psiFile1 = findFile(vFile);
       if (psiFile1 != null && fileViewProvider != null && fileViewProvider.isPhysical()) { // might get collected
-        Assert.assertEquals(psiFile1.getClass(), fileViewProvider.getPsi(fileViewProvider.getBaseLanguage()).getClass());
+        assert psiFile1.getClass().equals(fileViewProvider.getPsi(fileViewProvider.getBaseLanguage()).getClass());
       }
     }
 
Project JetBrains/intellij-community in file ...psi.impl.source.PostprocessReformattingAspect.java (2009-09-01)
@@ -36,7 +36,6 @@ import com.intellij.psi.impl.source.tree.*;
 import com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil;
 import com.intellij.util.LocalTimeCounter;
 import com.intellij.util.text.CharArrayUtil;
-import junit.framework.Assert;
 import org.jetbrains.annotations.NonNls;
 import org.jetbrains.annotations.NotNull;
 
@@ -302,7 +301,7 @@ public class PostprocessReformattingAspect implements PomModelAspect, Disposable
 
       if (!expectedPsi.equals(actualPsiTree)) {
         myReformatElements.clear();
-        Assert.assertEquals("Refactored psi should be the same as result of parsing", expectedPsi, actualPsiTree);
+        assert expectedPsi.equals(actualPsiTree): "Refactored psi should be the same as result of parsing";
       }
     }