com.atlassian.confluence.testbatching.junitreport
Class JUnitTestTimeWeightCalculator

java.lang.Object
  extended by com.atlassian.confluence.testbatching.junitreport.JUnitTestTimeWeightCalculator
All Implemented Interfaces:
TestWeightCalculator

public class JUnitTestTimeWeightCalculator
extends java.lang.Object
implements TestWeightCalculator

A TestWeightCalculator which uses the test timings recorded in JUnit test reports to calculate the "weight" of individual test classes. Tests that take longer to run according to the report are given a heavier weight.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.atlassian.confluence.testbatching.TestWeightCalculator
TestWeightCalculator.TestCounter
 
Constructor Summary
JUnitTestTimeWeightCalculator(JUnitTestTimings testTimings)
           
 
Method Summary
 long calculateTestWeight(java.lang.Class<?> testClass)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JUnitTestTimeWeightCalculator

public JUnitTestTimeWeightCalculator(JUnitTestTimings testTimings)
Method Detail

calculateTestWeight

public long calculateTestWeight(java.lang.Class<?> testClass)
Specified by:
calculateTestWeight in interface TestWeightCalculator
Returns:
the calculated "weight" of the given test class. The returned values from this class are the predicted execution time of all of the tests in the class, in milliseconds, although this should not be relied on.


Copyright © 2003-2014 Atlassian. All Rights Reserved.