Skip to content

Commit

Permalink
apiv2 test: add regression test for containers#12904
Browse files Browse the repository at this point in the history
Add a regression test for issue containers#12904 to make sure that attaching with
logs=true to the compact endpoint does not blow up.  Note that I did not
find a way to test the output (i.e., '123'); logs are sent in a binary
format and I did not find a way to compare the control characters.

Signed-off-by: Valentin Rothberg <[email protected]>
  • Loading branch information
vrothberg committed Jan 19, 2022
1 parent 094b11c commit af6a43f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/apiv2/20-containers.at
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ podman rm -a -f &>/dev/null

t GET "libpod/containers/json (at start: clean slate)" 200 length=0

# Regression test for #12904
podman run --rm -d --replace --name foo $IMAGE sh -c "echo 123;sleep 42"
t POST "containers/foo/attach?logs=true&stream=false" 200
t POST "containers/foo/kill" 204

podman run -v /tmp:/tmp $IMAGE true

t GET libpod/containers/json 200 length=0
Expand Down

0 comments on commit af6a43f

Please sign in to comment.