congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
Result.getRunTime
Code IndexAdd Tabnine to your IDE (free)

How to use
getRunTime
method
in
org.junit.runner.Result

Best Java code snippets using org.junit.runner.Result.getRunTime (Showing top 20 results out of 315)

origin: jamesdbloom/mockserver

@Override
public void testRunFinished(Result result) {
  if (result != null) {
    System.out.println("testRunFinished " + String.valueOf(result)
      + " time:" + String.valueOf(result.getRunTime())
      + " R" + String.valueOf(result.getRunCount())
      + " F" + String.valueOf(result.getFailureCount())
      + " I" + String.valueOf(result.getIgnoreCount())
    );
  }
}
origin: junit-team/junit4

@Override
public void testRunFinished(Result result) {
  printHeader(result.getRunTime());
  printFailures(result);
  printFooter(result);
}
origin: google/j2objc

@Override
public void testRunFinished(Result result) {
  printHeader(result.getRunTime());
  printFailures(result);
  printFooter(result);
}
origin: apache/usergrid

public Result execute() {
  Preconditions.checkState( isStarted.get(), "Cannot execute a tracker that has not started!" );
  Result result = new JUnitCore().run( testClass );
  long runTime = result.getRunTime();
  // collect some statistics
  maxTime = Math.max( maxTime, runTime );
  minTime = Math.min( minTime, runTime );
  long timesRun = actualIterations.incrementAndGet();
  long totalTime = totalRunTime.addAndGet( runTime );
  totalTestsRun.addAndGet( result.getRunCount() );
  meanTime = totalTime / timesRun;
  if ( ! result.wasSuccessful() ) {
    failures.addAndGet( result.getFailureCount() );
    ignores.addAndGet( result.getIgnoreCount() );
  }
  resultsLog.write( result );
  return result;
}
origin: h2oai/h2o-2

@Override public void testRunFinished(Result result) {
 printHeader(result.getRunTime());
 printFailures(result);
 printFooter(result);
}
origin: h2oai/h2o-2

 public static void main(String[] args) {
  try {
   H2O.main(args);
   TestUtil.stall_till_cloudsize(3);
   List<Class> tests = JUnitRunner.all();
   Result r = org.junit.runner.JUnitCore.runClasses(tests.toArray(new Class[0]));
   if( r.getFailureCount() == 0 ) {
    System.out.println("Successfully ran the following tests in " + (r.getRunTime() / 1000) + "s");
    for( Class c : tests )
     System.out.println(c.getName());
   } else {
    for( Failure f : r.getFailures() ) {
     System.err.println(f.getDescription());
     if( f.getException() != null )
      f.getException().printStackTrace();
    }
   }
   System.exit(r.getFailureCount());
  } catch( Throwable t ) {
   t.printStackTrace();
   System.exit(1);
  }
 }
}
origin: com.novocode/junit-interface

@Override
public void testRunFinished(Result result)
{
 debugOrInfo(c("Test run finished: ", INFO)+
  c(result.getFailureCount()+" failed", result.getFailureCount() > 0 ? ERRCOUNT : INFO)+
  c(", ", INFO)+
  c(result.getIgnoreCount()+" ignored", result.getIgnoreCount() > 0 ? IGNCOUNT : INFO)+
  c(", "+result.getRunCount()+" total, "+(result.getRunTime()/1000.0)+"s", INFO));
}
origin: camunda/camunda-bpm-platform

@Override
public void testRunFinished(Result result) {
  printHeader(result.getRunTime());
  printFailures(result);
  printFooter(result);
}
origin: apache/phoenix

  @Override
  public void testRunFinished(Result result) {
    printHeader(result.getRunTime());
    printFailures(result);
    printSummary(result);
    fWriter.println();
    printFooter(result);
  }
};
origin: SpoonLabs/nopol

@Override
public long getRunTime() {
  long total = 0;
  for (Result result : results()) {
    total += result.getRunTime();
  }
  return total;
}
origin: us.ihmc/ihmc-continuous-integration-core-tools

  public void performAnalyticsAndGenerateAnnotations(Result result)
  {      
   Map<String, AgileTestingClassPath> nameToPathMap = AgileTestingTools.mapAllClassNamesToClassPaths(SourceTools.getProjectPath());

   for (AtomicTestRun atomicTestRun : runs)
   {
     AgileTestingTestMethodAnnotationWriter.writeAnnotationsForTestRun(atomicTestRun, nameToPathMap, nameToPathMap.get(atomicTestRun.getClassName()));
   }
   
   PrintTools.info(this, "Total run time: " + new DecimalFormat("0.0").format(((double) result.getRunTime()) / 1000.0) + " s");
  }
}
origin: us.ihmc/ihmc-ci-plugin-plugin

  public void performAnalyticsAndGenerateAnnotations(Result result)
  {      
   Map<String, AgileTestingClassPath> nameToPathMap = AgileTestingTools.mapAllClassNamesToClassPaths(SourceTools.getProjectPath());

   for (AtomicTestRun atomicTestRun : runs)
   {
     AgileTestingTestMethodAnnotationWriter.writeAnnotationsForTestRun(atomicTestRun, nameToPathMap, nameToPathMap.get(atomicTestRun.getClassName()));
   }
   
   PrintTools.info(this, "Total run time: " + new DecimalFormat("0.0").format(((double) result.getRunTime()) / 1000.0) + " s");
  }
}
origin: io.tourniquet.junit/tourniquet-core

private void copyFields(final Result old, final Result result) throws NoSuchFieldException, IllegalAccessException {
  final AtomicInteger count = getAccessibleResultField(result, "count");
  count.set(old.getRunCount());
  final AtomicInteger ignoreCount = getAccessibleResultField(result, "ignoreCount");
  ignoreCount.set(old.getIgnoreCount());
  final AtomicLong runTime = getAccessibleResultField(result, "runTime");
  runTime.set(old.getRunTime());
  final AtomicLong startTime = getAccessibleResultField(result, "startTime");
  startTime.set(((AtomicLong) getAccessibleResultField(old, "startTime")).get());
}
origin: se.redmind/rmtest-core

public void setResult(Result result) {
  this.totalFail = result.getFailureCount();
  this.totalIgnored = result.getIgnoreCount();
  this.runTime = (double) result.getRunTime() / 1000;
  this.success = result.wasSuccessful();
}
origin: com.oracle/truffle-tck

@Override
public void testRunFinished(Result result) {
  printHeader(result.getRunTime());
  printFailures(result);
  printFooter(result);
}
origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.junit

@Override
public void testRunFinished(Result result) {
  printHeader(result.getRunTime());
  printFailures(result);
  printFooter(result);
}
origin: org.junit/com.springsource.org.junit

@Override
public void testRunFinished(Result result) {
  printHeader(result.getRunTime());
  printFailures(result);
  printFooter(result);
}
origin: blackboard/lambda-selenium

public TestResult(Result result) {
  runCount = result.getRunCount();
  failureCount = result.getFailureCount();
  ignoreCount = result.getIgnoreCount();
  runTime = result.getRunTime();
  if (!wasSuccessful()) {
    throwable = result.getFailures().get(0).getException();
  }
}
origin: io.hawt/hawtio-junit

public ResultDTO(Result result) {
  this.successful = result.wasSuccessful();
  this.ignoreCount = result.getIgnoreCount();
  this.failureCount = result.getFailureCount();
  this.runCount = result.getRunCount();
  this.runTime = result.getRunTime();
  List<Failure> failureList = result.getFailures();
  for (Failure failure : failureList) {
    failures.add(new FailureDTO(failure));
  }
}
origin: apache/jena

@Override
public void testRunFinished(Result result) {
  printHeader(result.getRunTime());
  printFailures(result);
  printFooter(result);
}
protected void printHeader(long runTime) {
org.junit.runnerResultgetRunTime

Popular methods of Result

  • getFailures
  • getFailureCount
  • wasSuccessful
  • getRunCount
  • <init>
  • getIgnoreCount
  • createListener
    Internal use only.

Popular in Java

  • Reading from database using SQL prepared statement
  • putExtra (Intent)
  • getResourceAsStream (ClassLoader)
  • requestLocationUpdates (LocationManager)
  • BufferedReader (java.io)
    Wraps an existing Reader and buffers the input. Expensive interaction with the underlying reader is
  • MalformedURLException (java.net)
    This exception is thrown when a program attempts to create an URL from an incorrect specification.
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • HashSet (java.util)
    HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
  • ResourceBundle (java.util)
    ResourceBundle is an abstract class which is the superclass of classes which provide Locale-specifi
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now