File tree Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,8 @@ And read the `Makefile` source to find other useful targets
2121
22220 - Global ` oci-runtime-tool ` options.
2323
24+ 1 - ` oci-runtime-tool generate ` .
25+
2426## Dependencies
2527
2628* [ GNU Core Utilities] [ coreutils ] for [ ` cat ` ] [ cat.1 ] ,
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ test_description=' Test generate output'
4+
5+ . ./sharness.sh
6+
7+ test_expect_success CAT,HEAD ' Test oci-runtime-tool generate writing to stdout' "
8+ oci-runtime-tool generate | head -n2 >actual &&
9+ cat <<EOF >expected &&
10+ {
11+ \" ociVersion\" : \" 1.0.0\" ,
12+ EOF
13+ test_cmp expected actual
14+ "
15+
16+ test_expect_success CAT,HEAD ' Test oci-runtime-tool generate --output' "
17+ oci-runtime-tool generate --output config.json &&
18+ head -n2 config.json >actual &&
19+ cat <<EOF >expected &&
20+ {
21+ \" ociVersion\" : \" 1.0.0\" ,
22+ EOF
23+ test_cmp expected actual
24+ "
25+
26+ test_done
You can’t perform that action at this time.
0 commit comments