summaryrefslogtreecommitdiff
path: root/src/test/strings.zig
diff options
context:
space:
mode:
authorTaylan Kammer <taylan.kammer@gmail.com>2026-06-04 19:47:54 +0200
committerTaylan Kammer <taylan.kammer@gmail.com>2026-06-04 19:47:54 +0200
commitcd25a1acae128b660f60a0132ffb981e08442cd4 (patch)
treeb1f86022131d68a2ea085fa53119fb8d0a89dbcc /src/test/strings.zig
parenta2315e8df140d8cc58da39942f471e9b8df19ba7 (diff)
Fix tests.
Diffstat (limited to 'src/test/strings.zig')
-rw-r--r--src/test/strings.zig6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/test/strings.zig b/src/test/strings.zig
index 58a460b..b8db320 100644
--- a/src/test/strings.zig
+++ b/src/test/strings.zig
@@ -13,13 +13,13 @@ test "istr" {
const s1 = "foo bar baz";
const v1 = istr.intern(s1);
const v1_len: usize = @intCast(fx.unpack(istr.len(v1)));
- try testing.expectEqualStrings(s1, istr.assert(v1).bytes());
+ try testing.expectEqualStrings(s1, istr.assert(v1).str());
try testing.expectEqual(s1.len, v1_len);
const s2 = @embedFile("data/string.txt");
const v2 = istr.intern(s2);
const v2_len: usize = @intCast(fx.unpack(istr.len(v2)));
- try testing.expectEqualStrings(s2, istr.assert(v2).bytes());
+ try testing.expectEqualStrings(s2, istr.assert(v2).str());
try testing.expectEqual(s2.len, v2_len);
// Check that modifying a slice doesn't affect the string.
@@ -27,5 +27,5 @@ test "istr" {
var s3 = "test".*;
const v3 = istr.intern(&s3);
s3[0] = 'x';
- try testing.expectEqualStrings("test", istr.assert(v3).bytes());
+ try testing.expectEqualStrings("test", istr.assert(v3).str());
}