Skip to content

Commit

Permalink
Sort threads to run slowest group first #1
Browse files Browse the repository at this point in the history
  • Loading branch information
Krisell authored Nov 10, 2021
1 parent e43ec57 commit d16f11c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/test-suites.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ function distributeTestsByWeight(testSuitePaths) {
threads[0].list.push(key);
threads[0].weight += +value;
}

// Run slowest group first
threads.sort((a, b) => b.weight - a.weight);

return threads;
}
Expand Down

0 comments on commit d16f11c

Please sign in to comment.