remove quoting around cleanup and disable lint for those lines. also make cleanup test more robust
This commit is contained in:
@@ -11,12 +11,12 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "remove exited containers" {
|
||||
run dokku run $TEST_APP hostname
|
||||
# make sure we have many exited containers of the same 'type'
|
||||
run bash -c "for cnt in 1 2 3; do dokku run $TEST_APP hostname; done"
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
container="$output"
|
||||
assert_success
|
||||
run bash -c "docker ps -a -f 'status=exited' -q --no-trunc=false | grep -q $container"
|
||||
run bash -c "docker ps -a -f 'status=exited' --no-trunc=false | grep '/exec hostname'"
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
assert_success
|
||||
@@ -24,7 +24,8 @@ teardown() {
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
assert_success
|
||||
run bash -c "docker ps -a -f 'status=exited' -q --no-trunc=false | grep -q $container"
|
||||
sleep 5 # wait for dokku cleanup to happen in the background
|
||||
run bash -c "docker ps -a -f 'status=exited' --no-trunc=false | grep '/exec hostname'"
|
||||
echo "output: "$output
|
||||
echo "status: "$status
|
||||
assert_failure
|
||||
|
||||
Reference in New Issue
Block a user