mirror of https://github.com/sbt/sbt.git
Handle empty case in `labelsAndDirs`
This commit is contained in:
parent
5e44ec7c53
commit
3d6e0f9327
|
|
@ -96,14 +96,15 @@ final class ScriptedTests(resourceBaseDirectory: File,
|
||||||
(groupName, testName) -> testDirectory
|
(groupName, testName) -> testDirectory
|
||||||
}
|
}
|
||||||
|
|
||||||
val batchSeed = labelsAndDirs.size / sbtInstances
|
if (labelsAndDirs.isEmpty) List()
|
||||||
val batchSize = if (batchSeed == 0) labelsAndDirs.size else batchSeed
|
else {
|
||||||
labelsAndDirs
|
val batchSeed = labelsAndDirs.size / sbtInstances
|
||||||
.grouped(batchSize)
|
val batchSize = if (batchSeed == 0) labelsAndDirs.size else batchSeed
|
||||||
.map { batch => () =>
|
labelsAndDirs
|
||||||
IO.withTemporaryDirectory(runBatchedTests(batch, _, prescripted, log))
|
.grouped(batchSize)
|
||||||
}
|
.map(batch => () => IO.withTemporaryDirectory(runBatchedTests(batch, _, prescripted, log)))
|
||||||
.toList
|
.toList
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Defines an auto plugin that is injected to sbt between every scripted session.
|
/** Defines an auto plugin that is injected to sbt between every scripted session.
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue