这是indexloc提供的服务,不要输入任何密码
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tests/unit/apps_1.bats
Original file line number Diff line number Diff line change
Expand Up @@ -139,11 +139,11 @@ teardown() {
run /bin/bash -c "dokku apps:list | grep $TEST_APP"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
run /bin/bash -c "curl --silent --write-out '%{http_code}\n' $(dokku url great-test-name) | grep 404"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
run /bin/bash -c "dokku --force apps:destroy great-test-name"
echo "output: $output"
echo "status: $status"
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/apps_2.bats
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ teardown() {
run /bin/bash -c "curl --silent --write-out '%{http_code}\n' $(dokku url great-test-name) | grep 404"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
run /bin/bash -c "dokku --force apps:destroy great-test-name"
echo "output: $output"
echo "status: $status"
Expand Down Expand Up @@ -136,7 +136,7 @@ teardown() {
run /bin/bash -c "dokku config:get app-without-ssl DOKKU_PROXY_SSL_PORT"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
run /bin/bash -c "dokku --force apps:destroy app-without-ssl"
echo "output: $output"
echo "status: $status"
Expand Down
16 changes: 8 additions & 8 deletions tests/unit/checks.bats
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_SKIPPED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku checks:enable $TEST_APP"
echo "output: $output"
Expand All @@ -66,12 +66,12 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_DISABLED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_SKIPPED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
}

@test "(checks) checks:disable -> checks:skip" {
Expand All @@ -88,7 +88,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_SKIPPED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku checks:skip $TEST_APP urgentworker,worker"
echo "output: $output"
Expand Down Expand Up @@ -132,7 +132,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_DISABLED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku checks:enable $TEST_APP"
echo "output: $output"
Expand All @@ -142,12 +142,12 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_SKIPPED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_DISABLED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
}

@test "(checks) checks:skip -> checks:disable" {
Expand All @@ -164,7 +164,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP DOKKU_CHECKS_DISABLED"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku checks:disable $TEST_APP urgentworker,worker"
echo "output: $output"
Expand Down
8 changes: 4 additions & 4 deletions tests/unit/config.bats
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ teardown() {
run /bin/bash -c "dokku config:get --global test_var"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
}

@test "(config) config:set/get" {
Expand Down Expand Up @@ -136,7 +136,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP test_var"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
}

@test "(config) config:unset" {
Expand All @@ -155,7 +155,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP test_var"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
run /bin/bash -c "dokku config:get $TEST_APP test_var3"
echo "output: $output"
echo "status: $status"
Expand All @@ -167,7 +167,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP test_var3"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
run /bin/bash -c "dokku config:unset $TEST_APP"
echo "output: $output"
echo "status: $status"
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/git_1.bats
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ teardown() {
run /bin/bash -c "dokku config:get $TEST_APP GIT_REV"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists
}

@test "(git) customize the GIT_REV environment variable" {
Expand Down
6 changes: 3 additions & 3 deletions tests/unit/logs.bats
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ teardown() {
echo "output: $output"
echo "status: $status"
assert_success
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku logs:report $TEST_APP --logs-max-size 2>&1"
echo "output: $output"
Expand Down Expand Up @@ -235,7 +235,7 @@ teardown() {
echo "output: $output"
echo "status: $status"
assert_success
assert_output ""
assert_output_not_exists
}

@test "(logs) logs:set escaped uri" {
Expand Down Expand Up @@ -532,7 +532,7 @@ teardown() {
echo "output: $output"
echo "status: $status"
assert_success
assert_output ""
assert_output_not_exists
}

@test "(logs) logs:vector" {
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/ports.bats
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ teardown() {
run /bin/bash -c "dokku ports:report $TEST_APP --ports-map"
echo "output: $output"
echo "status: $status"
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku ports:report $TEST_APP --ports-map-detected"
echo "output: $output"
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/storage.bats
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ teardown() {
echo "output: $output"
echo "status: $status"
assert_success
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku storage:mount $TEST_APP /tmp/mount:/mount"
echo "output: $output"
Expand All @@ -158,7 +158,7 @@ teardown() {
echo "output: $output"
echo "status: $status"
assert_success
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku storage:list $TEST_APP --format json | jq -r '. | length'"
echo "output: $output"
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/traefik.bats
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ teardown() {
echo "output: $output"
echo "status: $status"
assert_success
assert_output ""
assert_output_not_exists

run /bin/bash -c "dokku traefik:set --global letsencrypt-email test@example.com"
echo "output: $output"
Expand Down