| ... | ... | @@ -11,12 +11,17 @@ test { |
| 11 | 11 | |
| 12 | 12 | try expect(doc.mapping.get_string("id").?).toEqualString("g982zq6e8wsvnmduerpbf8787hu85brugmngn8wf"); |
| 13 | 13 | } |
| 14 | | test { |
| 14 | |
| 15 | fn fuzzCase(embedfile_content: []const u8) void { |
| 15 | 16 | const alloc = std.testing.allocator; |
| 16 | | const doc = yaml.parse(alloc, @embedFile("./fuzz/crashes/id:000000,sig:06,src:000000,time:2049,execs:911,op:quick,pos:263")) catch return; |
| 17 | const doc = yaml.parse(alloc, embedfile_content) catch return; |
| 17 | 18 | defer doc.deinit(alloc); |
| 18 | 19 | } |
| 19 | 20 | |
| 21 | // zig fmt: off |
| 22 | test { fuzzCase(@embedFile("./fuzz/crashes/id:000000,sig:06,src:000000,time:2049,execs:911,op:quick,pos:263")); } |
| 23 | // zig fmt: on |
| 24 | |
| 20 | 25 | fn parseTest(comptime basename: [:0]const u8) !void { |
| 21 | 26 | const alloc = std.testing.allocator; |
| 22 | 27 | const file = try nfs.cwd().openFile(yamltestsuite_root ++ "/src/" ++ basename, .{}); |