What problem does it solve?
Materialize has many test frameworks (cargo test, sqllogictest, testdrive, pgtest, mzcompose compositions), each with different invocation commands, rewrite flags, and conventions. This Skill removes the guesswork of picking the right framework and running it correctly, including rewriting expected results and reproducing flaky failures.
Core Features & Use Cases
- Framework selection guidance: Maps the type of change (SQL correctness, sources/sinks, pgwire protocol, restarts/upgrades, concurrency, limits, OOM, benchmarks) to the correct test framework and file location.
- Correct invocation commands: Provides exact commands such as
bin/sqllogictest -- PATH, bin/mzcompose --find NAME run WORKFLOW, and bin/cargo-test -p mz-environmentd pgtest, plus result rewriting via --rewrite-results or REWRITE=1.
- Flake and regression workflows: Covers reproducing flaky tests in loops, adding
log_filter instrumentation, version-guarding testdrive output, and verifying a regression test fails without the fix before passing with it.
- Use Case: After fixing a SQL bug, ask the Skill to add a regression test; it extends an existing
.slt file, runs it against the unfixed code to confirm it fails, then confirms it passes with the fix.
Quick Start
Run the sqllogictest file test/sqllogictest/aggregates.slt and rewrite its expected results if the output changed.