diff options
Diffstat (limited to 'test/system')
-rw-r--r-- | test/system/001-basic.bats | 7 | ||||
-rw-r--r-- | test/system/015-help.bats | 4 | ||||
-rw-r--r-- | test/system/110-history.bats | 2 | ||||
-rw-r--r-- | test/system/120-load.bats | 12 |
4 files changed, 20 insertions, 5 deletions
diff --git a/test/system/001-basic.bats b/test/system/001-basic.bats index 71595f419..b12836b9e 100644 --- a/test/system/001-basic.bats +++ b/test/system/001-basic.bats @@ -24,6 +24,13 @@ function setup() { is "${lines[0]}" "Version:[ ]\+[1-9][0-9.]\+" "Version line 1" is "$output" ".*Go Version: \+" "'Go Version' in output" is "$output" ".*API Version: \+" "API version in output" + + # Test that build date is reasonable, e.g. after 2019-01-01 + local built=$(expr "$output" : ".*Built: \+\(.*\)" | head -n1) + local built_t=$(date --date="$built" +%s) + if [ $built_t -lt 1546300800 ]; then + die "Preposterous 'Built' time in podman version: '$built'" + fi } diff --git a/test/system/015-help.bats b/test/system/015-help.bats index 42d3bd3ec..201b23b5e 100644 --- a/test/system/015-help.bats +++ b/test/system/015-help.bats @@ -40,7 +40,9 @@ function check_help() { [ -n "$usage" ] || die "podman $cmd: no Usage message found" # e.g. 'podman ps' should not show 'podman container ps' in usage - is "$usage" " $command_string .*" "Usage string matches command" + # Trailing space in usage handles 'podman system renumber' which + # has no ' [flags]' + is "$usage " " $command_string .*" "Usage string matches command" # If usage ends in '[command]', recurse into subcommands if expr "$usage" : '.*\[command\]$' >/dev/null; then diff --git a/test/system/110-history.bats b/test/system/110-history.bats index b83e90fe4..5dc221d61 100644 --- a/test/system/110-history.bats +++ b/test/system/110-history.bats @@ -3,8 +3,6 @@ load helpers @test "podman history - basic tests" { - skip_if_remote "FIXME: pending #7122" - tests=" | .*[0-9a-f]\\\{12\\\} .* CMD .* LABEL --format '{{.ID}} {{.Created}}' | .*[0-9a-f]\\\{12\\\} .* ago diff --git a/test/system/120-load.bats b/test/system/120-load.bats index 611799f8d..310ee55de 100644 --- a/test/system/120-load.bats +++ b/test/system/120-load.bats @@ -26,10 +26,18 @@ verify_iid_and_name() { is "$new_img_name" "$1" "Name & tag of restored image" } +@test "podman save to pipe and load" { + # We can't use run_podman because that uses the BATS 'run' function + # which redirects stdout and stderr. Here we need to guarantee + # that podman's stdout is a pipe, not any other form of redirection + $PODMAN save --format oci-archive $IMAGE | cat >$PODMAN_TMPDIR/test.tar + [ $status -eq 0 ] + + run_podman load -i $PODMAN_TMPDIR/test.tar +} -@test "podman load - by image ID" { - skip_if_remote "FIXME: pending #7123" +@test "podman load - by image ID" { # FIXME: how to build a simple archive instead? get_iid_and_name |