CI: split tests into fast and analysis-heavy lanes#927
Merged
erikdarlingdata merged 2 commits intodevfrom May 3, 2026
Merged
Conversation
Heavy Lite test classes (AnomalyDetector, FactCollector*, BaselineProvider, InferenceEngine, Scenario, AnalysisService) only run when paths under Lite/Analysis, Lite/Services, Lite/DuckDb, Lite/Models, or Lite.Tests change. Those tests dominate the build at ~5-6 of the 8 test minutes, but the logic underneath rarely changes. Cheap Lite tests (HealthCalculator, FactScorer, FinOps, FindingStore, Dismiss*, AlertHistorySource, DuckDbSchema) always run — together they finish in well under a minute. Also wires Installer.Tests into CI for the first time, gated on changes to Installer/, Installer.Core/, Installer.Tests/, install/, or upgrades/. Generated packages.lock.json so the project participates in --locked-mode restore + NuGet caching. Releases force-run everything regardless of paths.
VersionDetectionTests, IdempotencyTests, and AdversarialTests require a running SQL Server instance via TestDatabaseHelper, which the GitHub runner doesn't provide. Filter to only the pure-logic classes (UpgradeOrderingTests, FileFilteringTests) which already passed in the prior run.
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
AnomalyDetectorTests,FactCollectorTests,FactCollectorMiseryTests,BaselineProviderTests,InferenceEngineTests,ScenarioTests,AnalysisServiceTests— account for ~6 of the 8 test minutes. The logic underneath rarely changes, so they're gated on edits toLite/Analysis/**,Lite/Services/**,Lite/DuckDb/**,Lite/Models/**,Lite.Tests/**, orLite/PerformanceMonitorLite.csproj.HealthCalculator,FactScorer,FinOps,FindingStore,DismissReliability,DismissedArchiveSidecar,AlertHistorySource,DuckDbSchema.Installer.Testsinto CI for the first time (it existed but was never executed). Gated on changes toInstaller/**,Installer.Core/**,Installer.Tests/**,install/**, orupgrades/**. Generatedpackages.lock.jsonso it joins the existing NuGet cache +--locked-modeflow.Expected impact
Test plan
.github/workflows/build.ymlandInstaller.Tests/packages.lock.json, so the heavy Lite lane should be skipped on this build. Verify in the run log.Lite/Services/AnomalyDetector.cs(or rebase a feature branch that does) to confirm the heavy lane fires.🤖 Generated with Claude Code