Skip to content

Commit

Permalink
Avoid scheduling empty batches
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergey Chelombitko committed Dec 12, 2024
1 parent 606f44f commit bfdfcb0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions core/src/main/kotlin/com/malinskiy/marathon/Marathon.kt
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,11 @@ class Marathon(

override suspend fun scheduleTests(componentInfo: ComponentInfo) {
val parsedTests = testParser.extract(componentInfo)
val tests = applyTestFilters(parsedTests)
if (parsedTests.isEmpty()) return

logger.info("Scheduling {} tests for {} component: {}", tests.size, componentInfo.name, tests.joinToString(", ") { it.toTestName() })
val tests = applyTestFilters(parsedTests)
logger.info("Scheduling {} tests for {} component", tests.size, componentInfo.name)
logger.info(tests.joinToString(", ") { it.toTestName() })

val shard = prepareTestShard(tests, analytics)
scheduler.addTests(shard)
Expand Down

0 comments on commit bfdfcb0

Please sign in to comment.