summaryrefslogtreecommitdiff
path: root/build/tools.zig
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-11-20 04:38:59 -0300
committerGabriel Schneider <[email protected]>2026-11-20 04:39:53 -0300
commit403b46922af6e4e2012cd15f5f3f5a5702eef7e7 (patch)
tree44e4df5fbc12e77210fbcafa50f29d23c93caa05 /build/tools.zig
parenta3634ab3dbf2fabd997f137c47eafd7bc6c442b0 (diff)
downloadpardes-403b46922af6e4e2012cd15f5f3f5a5702eef7e7.tar.gz
pardes-403b46922af6e4e2012cd15f5f3f5a5702eef7e7.zip
test: test/lib becomes test/consumer, the package a consumer would write, in both of build.zig's head-comment shapes (pardes-build-2 item 5; the start design's step 3): `pardes-syntax` with `.grammars = .minimal` (lib.zig, as before), and `pardes-editor` with `.grammars = .none, .editor = true` and a grammar of its own, C's, built by this package from the very package pardes's manifest pins (`ts_c`, its own build's `tree-sitter-c` artifact, static, ReleaseFast) and linked into the editor's test and the bench, so the case sketchbook's examples/live is (pardes compiles no grammar for it; the program hands one in at run time) is gated here and not only in sketchbook; no network: `lib-test` runs it with `--pkg-dir ../../zig-pkg`, which has that package; the package is named `pardes_consumer` (a new fingerprint, as zig asks for a renamed package); lib-test's run step is named for what it is, so `--summary all` shows `zig build test in test/consumer, a package that depends on pardes success`, under `unit-test` as before; the package's own run: 29/29 steps, 11/11 tests (3 of the syntax, 8 of the editor), its bench builds and runs; build/tools.zig, build.zig's head comment, core/lib_syntax.zig, docs/next-editor.md, the manual and the changelog name test/consumer; the stale `test/lib/zig-pkg` (1.1 GB, untracked, from a run without --pkg-dir) deleted with the old directory. Scripts and notes outside the tree that name test/lib (its cache among them: a wipe of `test/lib/.zig-cache` now misses `test/consumer/.zig-cache`) are listed in the agent's report for the coordinator
Co-Authored-By: Claude Opus <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'build/tools.zig')
-rw-r--r--build/tools.zig7
1 files changed, 4 insertions, 3 deletions
diff --git a/build/tools.zig b/build/tools.zig
index 62e9817a..a4b41dd7 100644
--- a/build/tools.zig
+++ b/build/tools.zig
@@ -250,12 +250,13 @@ pub fn add(b: *std.Build, c: struct {
if (testMatch(b, c.unit_profile, c.test_filters, syntax_test_step)) |check| check.addArtifactArg(syntax_test);
// The library as a package that depends on pardes is given it
- // (`library`): test/lib's own `zig build test`, over the packages
+ // (`library`): test/consumer's own `zig build test`, over the packages
// this checkout has fetched.
const lib_test = b.addSystemCommand(&.{ b.graph.zig_exe, "build", "test", "--pkg-dir", "../../zig-pkg" });
- lib_test.setCwd(b.path("test/lib"));
+ lib_test.setName("zig build test in test/consumer, a package that depends on pardes");
+ lib_test.setCwd(b.path("test/consumer"));
lib_test.has_side_effects = true;
- const lib_test_step = b.step("lib-test", "build and test the library from a package that depends on pardes (test/lib)");
+ const lib_test_step = b.step("lib-test", "build and test the library from a package that depends on pardes (test/consumer)");
lib_test_step.dependOn(&lib_test.step);
const history = b.addExecutable(.{