diff options
author | Kenny Woodson <kwoodson@redhat.com> | 2017-02-08 09:22:48 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-08 09:22:48 -0500 |
commit | b1565e9e843e99c6b3c0d99518c27249472f57fe (patch) | |
tree | 41655090b99ee1a38ffde72d4dd6636a94da8f05 /roles/lib_utils/src | |
parent | 1321f28eb14f03a04ed4f3661629ca001ee83502 (diff) | |
parent | 3aa123c5b2b145e57776e297ac62e133b3f6993e (diff) | |
download | openshift-b1565e9e843e99c6b3c0d99518c27249472f57fe.tar.gz openshift-b1565e9e843e99c6b3c0d99518c27249472f57fe.tar.bz2 openshift-b1565e9e843e99c6b3c0d99518c27249472f57fe.tar.xz openshift-b1565e9e843e99c6b3c0d99518c27249472f57fe.zip |
Merge pull request #3285 from twiest/fix_unittests
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 |