diff options
Diffstat (limited to 'src/pardes.zig')
| -rw-r--r-- | src/pardes.zig | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pardes.zig b/src/pardes.zig index 1659a94b..803686e0 100644 --- a/src/pardes.zig +++ b/src/pardes.zig @@ -1695,7 +1695,9 @@ test "a REPL bound for a language takes the exec made on a body in it; tags, Exe var want: [32]u8 = undefined; try std.testing.expect(th.logHas(p, try std.fmt.bufPrint(&want, "ask {d} repl a b\n", .{file.serial}))); // A choice not offered is refused, and the question stands. - try std.testing.expectEqual(ctlfs.E.INVAL, th.wr(p, ctlfs.Node.of(file.serial, .ctl), "answer z\n").errno()); + const refused = th.wr(p, ctlfs.Node.of(file.serial, .ctl), "answer z\n"); + try std.testing.expectEqual(ctlfs.E.INVAL, refused.errno()); + try std.testing.expect(std.mem.endsWith(u8, refused.reply.ename, " \"z\"")); try std.testing.expectEqual(Pane.Prompt.repl_choice, file.prompt); const answered = th.wr(p, ctlfs.Node.of(file.serial, .ctl), "answer a\n"); try std.testing.expectEqual(ctlfs.Status.ok, answered.reply.status); |
