summaryrefslogtreecommitdiff
path: root/core/Plumb.zig
diff options
context:
space:
mode:
Diffstat (limited to 'core/Plumb.zig')
-rw-r--r--core/Plumb.zig6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/Plumb.zig b/core/Plumb.zig
index e1b09e69..402752a3 100644
--- a/core/Plumb.zig
+++ b/core/Plumb.zig
@@ -1345,7 +1345,7 @@ test "plumb: dispose: no rule and no dst, a start, the web port, a port no rule
// A start of a builtin runs it in place.
try testing.expect(send(p, null, .{ .type = "msg", .data = "hello" }, null) == .done);
const pane = p.panes[p.view().active].?;
- try testing.expectEqualStrings("hello", pane.msg[0..pane.msg_len]);
+ try testing.expectEqualStrings("hello", p.messages.saidBy(pane));
try testing.expectEqualStrings(e_client, send(p, null, .{ .type = "client" }, null).refused);
try testing.expectEqualStrings(e_no_start, send(p, null, .{ .type = "none" }, null).refused);
try testing.expectEqualStrings(e_no_start, send(p, null, .{ .dst = "nobody", .type = "x" }, null).refused);
@@ -1499,12 +1499,12 @@ test "plumb: the Plumb word opens the plumbing file, include basic until one is
// A rule after the word is refused, in words.
try testing.expect(p.executeBuiltinLine(0, "Plumb suffix .svg to image"));
const first = p.panes[0].?;
- try testing.expectEqualStrings(e_word, first.msg[0..first.msg_len]);
+ try testing.expectEqualStrings(e_word, p.messages.saidBy(first));
// Saved: its rules, or why not, the rules as they were.
saved(p, 0, path, "type is text\ndata matches 'x.*'\nplumb to web\n");
try testing.expectEqualStrings("type\tis\ttext\ndata\tmatches\t'x.*'\nplumb\tto\tweb\n\n", inForce(p));
saved(p, 0, path, "type is text\ndata isnt x\nplumb to web\n");
- try testing.expectEqualStrings("plumbing:2: unknown verb isnt", first.msg[0..first.msg_len]);
+ try testing.expectEqualStrings("plumbing:2: unknown verb isnt", p.messages.saidBy(first));
try testing.expectEqualStrings("type\tis\ttext\ndata\tmatches\t'x.*'\nplumb\tto\tweb\n\n", inForce(p));
// Another file saved is no plumbing.
saved(p, 0, "/elsewhere/plumbing", "type is text\nplumb to edit\n");