mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-11 17:12:51 +00:00
Merge pull request #7 from monopole/tweakTestScript2
Tweak test script2
This commit is contained in:
@@ -34,24 +34,20 @@ go install github.com/kubernetes-sigs/kustomize || \
|
|||||||
{ exit_with "Failed to install kustomize"; }
|
{ exit_with "Failed to install kustomize"; }
|
||||||
export PATH=$GOPATH/bin:$PATH
|
export PATH=$GOPATH/bin:$PATH
|
||||||
|
|
||||||
home=`pwd`
|
function runTest {
|
||||||
|
local script=$1
|
||||||
|
shift
|
||||||
|
local args=$@
|
||||||
|
|
||||||
### LDAP TEST ###
|
if [ ! -x "$script" ]; then
|
||||||
demo_dir="./demos/ldap"
|
exit_with "Unable to run $script"
|
||||||
if [ ! -d ${demo_dir} ]; then
|
|
||||||
exit_with "directory ${demo_dir} doesn't exist"
|
|
||||||
fi
|
|
||||||
|
|
||||||
test_script="${demo_dir}/integration_test.sh"
|
|
||||||
|
|
||||||
if [ -x "${test_script}" ]; then
|
|
||||||
${test_script} ${demo_dir}/base
|
|
||||||
if [ $? -eq 0 ]; then
|
|
||||||
echo "testing ${demo_dir} passed."
|
|
||||||
else
|
|
||||||
exit_with "testing ${demo_dir} failed."
|
|
||||||
fi
|
fi
|
||||||
else
|
|
||||||
exit_with "Unable to run ${test_script}"
|
$script "$args"
|
||||||
fi
|
if [ $? -ne 0 ]; then
|
||||||
#################
|
exit_with "Failed: $script $args"
|
||||||
|
fi
|
||||||
|
echo "$script passed."
|
||||||
|
}
|
||||||
|
|
||||||
|
runTest ldap/integration_test.sh ldap/base
|
||||||
|
|||||||
Reference in New Issue
Block a user