diff options
author | baude <bbaude@redhat.com> | 2018-02-08 10:40:43 -0600 |
---|---|---|
committer | baude <bbaude@redhat.com> | 2018-02-08 12:37:07 -0600 |
commit | c089cb9c9270aa4b367deb8c8c03cb05f8860a33 (patch) | |
tree | 8d765658f757798e1578fd2fc96f1528e6af5e20 /test/podman_pause.bats | |
parent | 8fdccb77648f5b772c6bae98fce4734b1a54ed4a (diff) | |
download | podman-c089cb9c9270aa4b367deb8c8c03cb05f8860a33.tar.gz podman-c089cb9c9270aa4b367deb8c8c03cb05f8860a33.tar.bz2 podman-c089cb9c9270aa4b367deb8c8c03cb05f8860a33.zip |
Final ginkgo migration
Completion of the migration from bats to ginkgo. This includes:
* load
* mount
* pause
* port
* run_networking
* search
Note: build will be done within a different PR
Signed-off-by: baude <bbaude@redhat.com>
Diffstat (limited to 'test/podman_pause.bats')
-rw-r--r-- | test/podman_pause.bats | 112 |
1 files changed, 0 insertions, 112 deletions
diff --git a/test/podman_pause.bats b/test/podman_pause.bats deleted file mode 100644 index 4e98eb130..000000000 --- a/test/podman_pause.bats +++ /dev/null @@ -1,112 +0,0 @@ -#!/usr/bin/env bats - -load helpers - -function setup() { - copy_images -} - -function teardown() { - cleanup_test -} - -@test "pause a bogus container" { - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} pause foobar - echo "$output" - [ "$status" -eq 125 ] -} - -@test "unpause a bogus container" { - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} unpause foobar - echo "$output" - [ "$status" -eq 125 ] -} - -@test "pause a created container by id" { - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} run -d $BB sleep 60 - echo "$output" - [ "$status" -eq 0 ] - ctr_id=`echo "$output" | tail -n 1` - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} pause $ctr_id - echo "$output" - [ "$status" -eq 0 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} unpause $ctr_id - echo "$output" - [ "$status" -eq 0 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} rm -f $ctr_id - echo "$output" - [ "$status" -eq 0 ] -} - -@test "pause a running container by id" { - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} run -d $BB sleep 60 - echo "$output" - [ "$status" -eq 0 ] - ctr_id=`echo "$output" | tail -n 1` - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} pause $ctr_id - echo "$output" - [ "$status" -eq 0 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} unpause $ctr_id - echo "$output" - [ "$status" -eq 0 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} rm -f $ctr_id - echo "$output" - [ "$status" -eq 0 ] -} - -@test "unpause a running container" { - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} run -d $BB sleep 60 - echo "$output" - [ "$status" -eq 0 ] - ctr_id=`echo "$output" | tail -n 1` - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} unpause $ctr_id - echo "$output" - [ "$status" -eq 125 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} rm -f $ctr_id - echo "$output" - [ "$status" -eq 0 ] -} - -@test "remove a paused container by id" { - skip "Test needs to wait for --force to work for podman rm" - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} run -d $BB sleep 60 - echo "$output" - [ "$status" -eq 0 ] - ctr_id=`echo "$output" | tail -n 1` - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} pause $ctr_id - echo "$output" - [ "$status" -eq 0 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} rm $ctr_id - echo "$output" - [ "$status" -eq 125 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} rm --force $ctr_id - echo "$output" - [ "$status" -eq 0 ] -} - -@test "stop a paused container created by id" { - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} run -d $BB sleep 60 - echo "$output" - [ "$status" -eq 0 ] - ctr_id=`echo "$output" | tail -n 1` - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} pause $ctr_id - echo "$output" - [ "$status" -eq 0 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} stop $ctr_id - echo "$output" - [ "$status" -eq 125 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} unpause $ctr_id - echo "$output" - [ "$status" -eq 0 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} ps -a --filter id=$ctr_id - echo "$output" - [ "$status" -eq 0 ] - # Container should be running after unpause and shouldn't - # be removable without the force flag. - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} rm $ctr_id - echo "$output" - [ "$status" -eq 125 ] - run ${PODMAN_BINARY} ${PODMAN_OPTIONS} rm -f $ctr_id - echo "$output" - [ "$status" -eq 0 ] -} |