summaryrefslogtreecommitdiff
path: root/build.zig
diff options
context:
space:
mode:
Diffstat (limited to 'build.zig')
-rw-r--r--build.zig23
1 files changed, 23 insertions, 0 deletions
diff --git a/build.zig b/build.zig
index c90485b6..78c01c61 100644
--- a/build.zig
+++ b/build.zig
@@ -1893,6 +1893,29 @@ pub fn build(b: *std.Build) void {
const behaviour_test_step = b.step("behaviour-test", "run the behavioural tests, through the 9P tree alone (test/behaviour/)");
behaviour_test_step.dependOn(&run_behaviour_tests.step);
if (testMatch(b, unit_profile, test_filters, behaviour_test_step)) |check| check.addArtifactArg(behaviour_tests);
+ // The 9P monkey at T1 (test/monkey9p.zig): random requests against
+ // an in-process session, the documented rules checked after each.
+ // Its fixed-seed smoke run is part of behaviour-test.
+ const monkey_session = b.addExecutable(.{
+ .name = "pardes-monkey-session",
+ .root_module = b.createModule(.{
+ .target = target,
+ .optimize = optimize,
+ .root_source_file = b.path("test/monkey9p.zig"),
+ .link_libc = true,
+ }),
+ });
+ monkey_session.root_module.addImport("session", session_module);
+ const run_monkey_session = b.addRunArtifact(monkey_session);
+ run_monkey_session.addPassthruArgs();
+ run_monkey_session.has_side_effects = true;
+ b.step("monkey-session", "random 9P requests against an in-process session, checking the documented rules (-- [--seed N]... [--steps M] [--only i,j,k] [--no-shrink] [-v])").dependOn(&run_monkey_session.step);
+ const run_monkey_session_smoke = b.addRunArtifact(monkey_session);
+ run_monkey_session_smoke.addArg("--smoke");
+ run_monkey_session_smoke.has_side_effects = true;
+ const monkey_session_smoke_step = b.step("monkey-session-smoke", "a short fixed-seed run of monkey-session (part of behaviour-test)");
+ monkey_session_smoke_step.dependOn(&run_monkey_session_smoke.step);
+ if (test_filters.len == 0) behaviour_test_step.dependOn(&run_monkey_session_smoke.step);
// Kitty graphics conformance at the core: what a terminal pane's
// program sends, what it reads back, what ghostty stores and what a