From 25998655880e7da0e267479bd7272a124bc53368 Mon Sep 17 00:00:00 2001 From: Dave Henderson Date: Sat, 10 Feb 2018 10:16:24 -0500 Subject: [PATCH] fixup! Allow vault address to be specified in the vault:// URL --- test/integration/helper.bash | 2 +- test/integration/test.sh | 16 ++++++++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100755 test/integration/test.sh diff --git a/test/integration/helper.bash b/test/integration/helper.bash index 8d3e46cf0..3309c8f45 100644 --- a/test/integration/helper.bash +++ b/test/integration/helper.bash @@ -28,7 +28,7 @@ function __gomplate_stdin () { function start_mirror_svc () { bin/mirror & - wait_for_url http://127.0.0.1:8080/ + # wait_for_url http://127.0.0.1:8080/ } function stop_mirror_svc () { diff --git a/test/integration/test.sh b/test/integration/test.sh new file mode 100755 index 000000000..270c1cdac --- /dev/null +++ b/test/integration/test.sh @@ -0,0 +1,16 @@ +#!/bin/bash +set -euo pipefail + +# This is useful for killing vault after the script exits, but causes the CircleCI +# build to fail, so... ¯\_(ツ)_/¯ +# trap "exit" INT TERM +# trap "kill 0" EXIT + +# TODO: export these in a bats helper, as well as only launch vault in a vault helper +export VAULT_ADDR=http://127.0.0.1:8200 +export VAULT_ROOT_TOKEN=00000000-1111-2222-3333-444455556666 + +# fire up vault in dev mode for the vault tests +vault server -dev -dev-root-token-id=${VAULT_ROOT_TOKEN} -log-level=err >&/dev/null & + +bats $(dirname $0)