feat: Real docker-based testing

This pull request switches testing to use an actual docker daemon, vs mocking everything out.

It may also catch actual breaking issues in our tests, which is great!
This commit is contained in:
Jose Diaz-Gonzalez
2019-03-18 14:44:28 -04:00
parent c14a807a7e
commit 744e65760b
34 changed files with 398 additions and 323 deletions

View File

@@ -2,13 +2,11 @@
load test_helper
setup() {
export ECHO_DOCKER_COMMAND="false"
dokku "$PLUGIN_COMMAND_PREFIX:create" l >&2
dokku "$PLUGIN_COMMAND_PREFIX:create" l
}
teardown() {
export ECHO_DOCKER_COMMAND="false"
dokku --force "$PLUGIN_COMMAND_PREFIX:destroy" l >&2
dokku --force "$PLUGIN_COMMAND_PREFIX:destroy" l
}
@test "($PLUGIN_COMMAND_PREFIX:connect) error when there are no arguments" {
@@ -22,7 +20,6 @@ teardown() {
}
@test "($PLUGIN_COMMAND_PREFIX:connect) success" {
export ECHO_DOCKER_COMMAND="true"
run dokku "$PLUGIN_COMMAND_PREFIX:connect" l
assert_contains 'docker exec -i -t dokku.redis.l redis-cli -a'
}