mirror of https://github.com/sbt/sbt.git
Fix #5801: Remove duplicate TaskDefs in test agent
When forking, a test could be run as many times as its `TestDef` matched `Fingerprint`s. When forking is disabled, sbt correctly runs the tests only once.
This commit is contained in:
parent
788fd4aa28
commit
5cce0e9d5d
|
|
@ -19,6 +19,7 @@ import java.util.ArrayList;
|
|||
import java.util.Arrays;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import java.util.LinkedHashSet;
|
||||
import java.util.concurrent.*;
|
||||
|
||||
public final class ForkMain {
|
||||
|
|
@ -326,7 +327,7 @@ public final class ForkMain {
|
|||
|
||||
if (framework == null) continue;
|
||||
|
||||
final ArrayList<TaskDef> filteredTests = new ArrayList<>();
|
||||
final LinkedHashSet<TaskDef> filteredTests = new LinkedHashSet<>();
|
||||
for (final Fingerprint testFingerprint : framework.fingerprints()) {
|
||||
for (final TaskDef test : tests) {
|
||||
// TODO: To pass in correct explicitlySpecified and selectors
|
||||
|
|
|
|||
Loading…
Reference in New Issue