Skip to content

Commit

Permalink
sort the list of test methods in PackageResults only once
Browse files Browse the repository at this point in the history
  • Loading branch information
nullin committed Jun 18, 2011
1 parent d934e77 commit 22a1035
Showing 1 changed file with 5 additions and 1 deletion.
Expand Up @@ -24,6 +24,7 @@ public class PackageResult extends BaseResult {
private transient int fail;
private transient int skip;
private transient int total;
private boolean sortedOnce = false;

public PackageResult(String name)
{
Expand Down Expand Up @@ -71,7 +72,10 @@ public long getAge() {
}

public List<MethodResult> getSortedTestMethodsByStartTime() {
sortTestMethods();
if (!sortedOnce) {
sortTestMethods();
sortedOnce = true;
}
return sortedTestMethodsByStartTime;
}

Expand Down

0 comments on commit 22a1035

Please sign in to comment.