summaryrefslogtreecommitdiff
path: root/src/ninep/ctl.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/ninep/ctl.zig')
-rw-r--r--src/ninep/ctl.zig3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ninep/ctl.zig b/src/ninep/ctl.zig
index 63f89cdf..fc0558f5 100644
--- a/src/ninep/ctl.zig
+++ b/src/ninep/ctl.zig
@@ -2932,7 +2932,8 @@ test "/index shows a name as the log does: a newline in it is \\n, controls spac
const index = rd(p, @intFromEnum(tree.TopFile.index), 0, 4096).bytes;
try testing.expect(std.mem.indexOf(u8, index, "/tmp/two\\nlines \\xff ") != null);
try testing.expectEqual(@as(usize, 1), std.mem.count(u8, index, "\n"));
- try testing.expectEqual(@as(u64, index.len), call(p, .{ .tag = 1, .op = .getattr, .node = @intFromEnum(tree.TopFile.index) }).reply.attr.size);
+ try testing.expect(index.len > 0);
+ try testing.expectEqual(@as(u64, 0), call(p, .{ .tag = 1, .op = .getattr, .node = @intFromEnum(tree.TopFile.index) }).reply.attr.size);
// Its tag never carries the raw newline either.
const tag = rd(p, Node.of(serialOf(p), .tag), 0, 4096).bytes;
try testing.expect(std.mem.indexOf(u8, tag, "/tmp/two\\nlines") != null);