diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/apiv2/01-basic.at | 8 | ||||
-rw-r--r-- | test/system/015-help.bats | 14 | ||||
-rw-r--r-- | test/system/250-systemd.bats | 3 |
3 files changed, 20 insertions, 5 deletions
diff --git a/test/apiv2/01-basic.at b/test/apiv2/01-basic.at index 96b6aef7c..541d8cbf1 100644 --- a/test/apiv2/01-basic.at +++ b/test/apiv2/01-basic.at @@ -18,11 +18,11 @@ t HEAD libpod/_ping 200 for i in /version version; do t GET $i 200 \ .Components[0].Name="Podman Engine" \ - .Components[0].Details.APIVersion=1.0.0 \ - .Components[0].Details.MinAPIVersion=1.0.0 \ + .Components[0].Details.APIVersion=2.0.0 \ + .Components[0].Details.MinAPIVersion=2.0.0 \ .Components[0].Details.Os=linux \ - .ApiVersion=1.0.0 \ - .MinAPIVersion=1.0.0 \ + .ApiVersion=1.40 \ + .MinAPIVersion=1.24 \ .Os=linux done diff --git a/test/system/015-help.bats b/test/system/015-help.bats index 4a3781012..651fdcd09 100644 --- a/test/system/015-help.bats +++ b/test/system/015-help.bats @@ -86,6 +86,20 @@ function check_help() { found[takes_no_args]=1 fi + # If command lists "-l, --latest" in help output, combine -l with arg. + # This should be disallowed with a clear message. + if expr "$full_help" : ".*-l, --latest" >/dev/null; then + local nope="exec list port ps top" # these can't be tested + if is_rootless; then + nope="$nope mount restore" # these don't work rootless + fi + if ! grep -wq "$cmd" <<<$nope; then + run_podman 125 "$@" $cmd -l nonexistent-container + is "$output" "Error: .*--latest and \(containers\|pods\|arguments\) cannot be used together" \ + "'$command_string' with both -l and container" + fi + fi + # If usage has required arguments, try running without them. # The expression here is 'first capital letter is not in [BRACKETS]'. # It is intended to handle 'podman foo [flags] ARG' but not ' [ARG]'. diff --git a/test/system/250-systemd.bats b/test/system/250-systemd.bats index bbb5a10fb..9bd3e15a1 100644 --- a/test/system/250-systemd.bats +++ b/test/system/250-systemd.bats @@ -41,7 +41,8 @@ function teardown() { fi cname=$(random_string) - run_podman create --name $cname --label "io.containers.autoupdate=image" --detach $IMAGE top + # See #7407 for --pull=always. + run_podman create --pull=always --name $cname --label "io.containers.autoupdate=image" --detach $IMAGE top run_podman generate systemd --new $cname echo "$output" > "$UNIT_FILE" |