From 1cc05817b79ee86855505df4d614075a98e1e847 Mon Sep 17 00:00:00 2001 From: Jose Diaz-Gonzalez Date: Mon, 7 Sep 2015 00:15:59 -0400 Subject: [PATCH] Use docker binstub instead of running install and dependencies --- Makefile | 2 -- tests/bin/docker | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+), 2 deletions(-) create mode 100755 tests/bin/docker diff --git a/Makefile b/Makefile index c3765bf..93a7332 100644 --- a/Makefile +++ b/Makefile @@ -37,7 +37,5 @@ unit-tests: setup: bash tests/setup.sh $(MAKE) ci-dependencies - ./install - ./dependencies test: setup lint unit-tests diff --git a/tests/bin/docker b/tests/bin/docker new file mode 100755 index 0000000..b56b55e --- /dev/null +++ b/tests/bin/docker @@ -0,0 +1,50 @@ +#!/usr/bin/env bash + +case "$1" in + stop) + echo "testid" + ;; + start) + echo "testid" + ;; + kill) + echo "testid" + ;; + run) + echo "testid" + ;; + rm) + echo "testid" + ;; + ps) + if [[ $@ = *"no-trunc"* ]]; then + echo "1479bbd60ade8a92617d2aeb4935bd3ff3179bd0fd71c22c3102c421f4bc221f" + exit 0 + else + echo "CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES" + echo "testid dokku/ruby-sample:latest \"/start web\" About an hour ago Up About an hour adoring_turing" + fi + ;; + exec) + echo "exec called with $@" + ;; + inspect) + if [[ $@ = *"IPAddress"* ]]; then + echo "172.17.0.34" + exit 0 + fi + + # running + echo "true" + ;; + images) + echo "REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE" + echo "redis 3.0.3 9216d5a4eec8 13 days ago 109.3 MB" + ;; + pull) + exit 0 + ;; + *) + exit "$DOKKU_NOT_IMPLEMENTED_EXIT" + ;; +esac