Faster CI with Mill: Selective Testing Strategies

2024-12-30

Running all tests in large codebases is inefficient. This article explores three selective testing approaches: folder-based, dependency-based, and heuristic-based. Folder-based is simple but may miss errors; dependency-based is more thorough but can over-test; heuristic-based optimizes test selection with custom rules, balancing speed and thoroughness. The Mill build tool natively supports dependency-based selective testing, significantly improving CI efficiency. However, combining it with heuristic methods further optimizes the balance between speed and test coverage.