Repository navigation
test(frontend-metricsql): restore the external MetricsQL corpus test as a lowering corpus - #1501
Merged
Conversation
…as a lowering corpus #1226 and #1229 deleted external_corpus.rs, so a nightly that runs an out-of-tree corpus through it now matches zero tests. Restore it as its own `external_corpus` target under tests/lowering_corpora/, per #1482: lowering only (no panics, per-file `# floor: N`, failure causes by count). Binding through Pass 1 is left out; planning an external corpus end to end is #1498. Closes #1497. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
milindsrivastava1997
deleted the
1497-testfrontend-metricsql-restore-the-external-metricsql-corpus-test-as-a-lowering-corpus
branch
November 25, 2026 16:44
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.
Closes #1497.
Summary
#1226 and #1229 deleted
crates/frontend-metricsql/tests/external_corpus.rs, so a nightly that runs an out-of-tree MetricsQL corpus through it now matches zero tests. This restores it as its ownexternal_corpustarget undertests/lowering_corpora/, following #1482. It checks lowering only; binding through Pass 1 crossed stage crates and is left out (planning an external corpus end to end is #1498).Review guide
crates/frontend-metricsql/tests/lowering_corpora/external_corpus/external_corpus.rs:queries,floor,normalizeandfloor_lineare restored unchanged from6bcf398^.check_dirlowers every query of every*.txtin a directory withlower_metricsql_query(q, 15s), enforces each file's# floor: Nand prints failure causes by count.corpus_lowersruns it on$ASAP_EXTERNAL_CORPUS_DIR(skipped when unset);floor_is_enforced_per_fileruns it on a sample directory, so PR CI exercises the logic.crates/frontend-metricsql/Cargo.toml: the new[[test]]target.Behavior: before → after
Interfaces
# asap-frontend-metricsql test targets +external_corpus tests/lowering_corpora/external_corpus/external_corpus.rsAlgorithm changes
None.
Decisions and open questions
lowering_corporatargets, rather than a module of themetricsqlbinary.asap_plannerbinary.tests/, whichplanning_crates_read_no_environment_variablesdoes not cover.Verification
cargo test -p asap-frontend-metricsql --test external_corpus, variable unset: 3 passed.ASAP_EXTERNAL_CORPUS_DIR: passes; every file at or above its floor.cargo fmt --check,cargo clippy -D warningsclean; pre-commitcargo testpassed.cargo test -p asap-integration-tests --test integration crate_graph::: 8 passed.Follow-ups
🤖 Generated with Claude Code