File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -371,7 +371,7 @@ test "image define OS jsonParse" {
371371 // Other
372372 var osOther = std .json .Scanner .initCompleteInput (
373373 testing .allocator ,
374- "\" unknown \" " ,
374+ "\" other \" " ,
375375 );
376376
377377 defer osOther .deinit ();
Original file line number Diff line number Diff line change 77 _ = @import ("image/define_os.zig" );
88 _ = @import ("image/define_arch.zig" );
99 _ = @import ("image/define_media_type.zig" );
10+ _ = @import ("runtime/config.zig" );
1011}
Original file line number Diff line number Diff line change 1+ const std = @import ("std" );
2+ const utils = @import ("../utils.zig" );
3+ const ocispec = @import ("ocispec" );
4+ const runtime = ocispec .runtime ;
5+ const testing = std .testing ;
6+
7+ test "runtime config" {
8+ var arena = std .heap .ArenaAllocator .init (std .heap .page_allocator );
9+ defer arena .deinit ();
10+
11+ const allocator = arena .allocator ();
12+
13+ const ruuntimeFile = "runtime_spec.json" ;
14+ const ruuntimeFile_path = try std .mem .concat (
15+ allocator ,
16+ u8 ,
17+ &.{ "./tests/fixtures/" , ruuntimeFile },
18+ );
19+ const spec = try runtime .Spec .initFromFile (allocator , ruuntimeFile_path );
20+
21+ try testing .expectEqualStrings (spec .ociVersion , "0.5.0-dev" );
22+ }
You can’t perform that action at this time.
0 commit comments