diff options
author | Thomas Wiest <twiest@redhat.com> | 2017-02-07 16:39:51 -0500 |
---|---|---|
committer | Thomas Wiest <twiest@redhat.com> | 2017-02-07 23:14:06 -0500 |
commit | 3aa123c5b2b145e57776e297ac62e133b3f6993e (patch) | |
tree | 1a81e5b6e304e4902fcf8f5c6de8a49061d3fd39 /roles/lib_utils/src | |
parent | 5a933ed4b33131423b2f349eb0bc33ead99ec360 (diff) | |
download | openshift-3aa123c5b2b145e57776e297ac62e133b3f6993e.tar.gz openshift-3aa123c5b2b145e57776e297ac62e133b3f6993e.tar.bz2 openshift-3aa123c5b2b145e57776e297ac62e133b3f6993e.tar.xz openshift-3aa123c5b2b145e57776e297ac62e133b3f6993e.zip |
Fixed ansible module unit and integration tests and added runners.
Diffstat (limited to 'roles/lib_utils/src')
-rwxr-xr-x | roles/lib_utils/src/test/generate-and-run-tests.sh | 42 | ||||
-rwxr-xr-x | roles/lib_utils/src/test/integration/yedit.yml (renamed from roles/lib_utils/src/test/integration/yedit_test.yml) | 5 |
2 files changed, 45 insertions, 2 deletions
diff --git a/roles/lib_utils/src/test/generate-and-run-tests.sh b/roles/lib_utils/src/test/generate-and-run-tests.sh new file mode 100755 index 000000000..4b534c8f2 --- /dev/null +++ b/roles/lib_utils/src/test/generate-and-run-tests.sh @@ -0,0 +1,42 @@ +#!/bin/bash -e + + +# Put us in the same dir as the script. +cd $(dirname $0) + +echo +echo "Running lib_openshift generate" +echo "------------------------------" +../generate.py + + +echo +echo "Running lib_utils Unit Tests" +echo "----------------------------" +cd unit + +for test in *.py; do + echo + echo "--------------------------------------------------------------------------------" + echo + echo "Running $test..." + ./$test +done + + +echo +echo "Running lib_utils Integration Tests" +echo "-----------------------------------" +cd ../integration + +for test in *.yml; do + echo + echo "--------------------------------------------------------------------------------" + echo + echo "Running $test..." + ./$test -vvv +done + +# Clean up this damn file +# TODO: figure out why this is being written and clean it up. +rm kube-manager-test.yaml diff --git a/roles/lib_utils/src/test/integration/yedit_test.yml b/roles/lib_utils/src/test/integration/yedit.yml index 1760a7466..e3dfd490b 100755 --- a/roles/lib_utils/src/test/integration/yedit_test.yml +++ b/roles/lib_utils/src/test/integration/yedit.yml @@ -1,8 +1,9 @@ -#!/usr/bin/ansible-playbook +#!/usr/bin/ansible-playbook --module-path=../../../library/ +# # Yedit test so that we can quickly determine if features are working # Ensure that the kube-manager.yaml file exists # -# ./yedit_test.yml -M ../../library +# ./yedit_test.yml # --- - hosts: localhost |