diff options
Diffstat (limited to 'src/Scripts.zig')
| -rw-r--r-- | src/Scripts.zig | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/Scripts.zig b/src/Scripts.zig index f71a2b5..fd5fde9 100644 --- a/src/Scripts.zig +++ b/src/Scripts.zig | |||
| @@ -233,6 +233,15 @@ test "script" { | |||
| 233 | try testing.expectEqual(Script.Latin, self.script('A').?); | 233 | try testing.expectEqual(Script.Latin, self.script('A').?); |
| 234 | } | 234 | } |
| 235 | 235 | ||
| 236 | fn testAllocator(allocator: Allocator) !void { | ||
| 237 | var prop = try Scripts.init(allocator); | ||
| 238 | prop.deinit(allocator); | ||
| 239 | } | ||
| 240 | |||
| 241 | test "Allocation failure" { | ||
| 242 | try testing.checkAllAllocationFailures(testing.allocator, testAllocator, .{}); | ||
| 243 | } | ||
| 244 | |||
| 236 | const std = @import("std"); | 245 | const std = @import("std"); |
| 237 | const builtin = @import("builtin"); | 246 | const builtin = @import("builtin"); |
| 238 | const compress = std.compress; | 247 | const compress = std.compress; |