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 ocitools options.
2323
24+ 1 - ` ocitools 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 ocitools generate writing to stdout' "
8+ ocitools generate | head -n2 >actual &&
9+ cat <<EOF >expected &&
10+ {
11+ \" ociVersion\" : \" 1.0.0-rc1\" ,
12+ EOF
13+ test_cmp expected actual
14+ "
15+
16+ test_expect_success CAT,HEAD ' Test ocitools generate --output' "
17+ ocitools generate --output config.json &&
18+ head -n2 config.json >actual &&
19+ cat <<EOF >expected &&
20+ {
21+ \" ociVersion\" : \" 1.0.0-rc1\" ,
22+ EOF
23+ test_cmp expected actual
24+ "
25+
26+ test_done
You can’t perform that action at this time.
0 commit comments