Executes the full dual-path test suite to verify project integrity after code changes.
Install
mkdir -p .claude/skills/build-and-test && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/14618" && unzip -o skill.zip -d .claude/skills/build-and-test && rm skill.zipInstalls to .claude/skills/build-and-test
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Rebuild cx and run the full dual-path test suite. UseKey capabilities
- →Rebuild the `cx` project
- →Run the full dual-path test suite
- →Verify tests under native path
- →Verify tests through self-hosted `cx`
- →Report pass/fail status for tests
- →Identify self-host path divergence
How it works
The skill executes a command to compile `cx.c` and then runs `tests/all.c` twice, once natively and once through the self-hosted `cx`, reporting the summary of passed tests.
Inputs & outputs
When to use build-and-test
- →Verifying system stability after C code changes
- →Running the dual-path regression suite
- →Debugging self-host path divergence
About this skill
build-and-test
The project's single verification gate. tests/all.c runs every
test twice — once natively (build/cx <file>) and once through
self-hosted cx (build/cx cx.c <file>). A change is not done until
both paths report SUMMARY: 45/45 tests passed.
The command
cc -Wall -Wpedantic -o build/cx cx.c && build/cx cx.c tests/all.c
That's it. No flags, no selection — run the whole suite. Selecting a subset hides regressions in other tests the change might have broken by accident.
Reading the output
The suite prints per-stage headers and per-test OK/FAIL lines. The line to grep for at the end is:
SUMMARY: N/45 tests passed.
45/45: done. Report success and stop.<45/45: regression. Find the firstFAIL:line (or the first stage that shows lower counts on its second pass), that's where the self-host path diverged.
When it fails under self-host only
A test that passes natively but fails the second time through is
almost always hitting one of the patterns in
.claude/rules/cx-constraints.md:
- stacked case labels
- break inside braced switch case
- local shadowing a non-zero global
- bytecode overflow of
code_pool - a stubbed
#else __cx__intrinsic branch
Narrow the failing test to the smallest repro, then check which pattern fits.
What not to do
- Don't
--no-verifyor-wyour way around warnings. Fix them. - Don't skip tests because they're "flaky." The suite is deterministic; flakiness means a real bug.
- Don't claim success on partial runs.
When not to use it
- →When changes are not to `cx.c`, `toys.c`, or `tests/*.c`
- →When only a subset of tests needs to be run
Limitations
- →The skill is specific to the `cx` project and its test suite
- →It requires all tests to pass for both execution paths
- →It does not allow selecting a subset of tests
How it compares
This skill automates the entire verification gate, ensuring all tests are run against both native and self-hosted paths, unlike manually running individual tests or only one execution path.
Compared to similar skills
build-and-test side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| build-and-test (this skill) | 0 | 4mo | No flags | Beginner |
| e2e-testing-patterns | 8 | 2mo | No flags | Intermediate |
| testing-workflow | 16 | 9mo | Review | Intermediate |
| perf-lighthouse | 13 | 5mo | Review | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
e2e-testing-patterns
wshobson
Master end-to-end testing with Playwright and Cypress to build reliable test suites that catch bugs, improve confidence, and enable fast deployment. Use when implementing E2E tests, debugging flaky tests, or establishing testing standards.
testing-workflow
amo-tech-ai
Comprehensive testing workflow for E2E, integration, and unit tests. Use when testing applications layer-by-layer, validating user journeys, or running test suites.
perf-lighthouse
tech-leads-club
Run Lighthouse audits locally via CLI or Node API, parse and interpret reports, set performance budgets. Use when measuring site performance, understanding Lighthouse scores, setting up budgets, or integrating audits into CI. Triggers on: lighthouse, run lighthouse, lighthouse score, performance audit, performance budget.
xcodebuildmcp
cameroncooke
Official skill for XcodeBuildMCP. Use when doing iOS/macOS/watchOS/tvOS/visionOS work (build, test, run, debug, log, UI automation).
verify
Use when you want to validate changes before committing, or when you need to check all React contribution requirements.
playwright-pro
alirezarezvani
Production-grade Playwright testing toolkit. Use when the user mentions Playwright tests, end-to-end testing, browser automation, fixing flaky tests, test migration, CI/CD testing, or test suites. Generate tests, fix flaky failures, migrate from Cypress/Selenium, sync with TestRail, run on BrowserStack. 55 templates, 3 agents, smart reporting.