diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2022-01-04 19:50:09 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-04 19:50:09 +0100 |
commit | 9a35494141f2a3614e6e2a4c3bc2d5c6d5db9e92 (patch) | |
tree | fe5ac223fb4bac476fb75076e8d99ed877ed5939 /test | |
parent | 47cf00eb1349e7823b2c4286e39a517ea4657242 (diff) | |
parent | 116a276e8ca28beca9e60a21680ab3cb94fd5aa1 (diff) | |
download | podman-9a35494141f2a3614e6e2a4c3bc2d5c6d5db9e92.tar.gz podman-9a35494141f2a3614e6e2a4c3bc2d5c6d5db9e92.tar.bz2 podman-9a35494141f2a3614e6e2a4c3bc2d5c6d5db9e92.zip |
Merge pull request #12643 from leahneukirchen/events-compat
legacy events: also set Action="die"
Diffstat (limited to 'test')
-rw-r--r-- | test/apiv2/27-containersEvents.at | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/test/apiv2/27-containersEvents.at b/test/apiv2/27-containersEvents.at new file mode 100644 index 000000000..a86f2e353 --- /dev/null +++ b/test/apiv2/27-containersEvents.at @@ -0,0 +1,27 @@ +# -*- sh -*- +# +# test container-related events +# + +podman pull $IMAGE &>/dev/null + +# Ensure clean slate +podman rm -a -f &>/dev/null + +START=$(date +%s) + +podman run $IMAGE false || true + +# libpod api +t GET "libpod/events?stream=false&since=$START" 200 \ + 'select(.status | contains("start")).Action=start' \ + 'select(.status | contains("died")).Action=died' \ + 'select(.status | contains("died")).Actor.Attributes.containerExitCode=1' + +# compat api, uses status=die (#12643) +t GET "events?stream=false&since=$START" 200 \ + 'select(.status | contains("start")).Action=start' \ + 'select(.status | contains("die")).Action=die' \ + 'select(.status | contains("die")).Actor.Attributes.exitCode=1' + +# vim: filetype=sh |