diff options
Diffstat (limited to 'moon_forming')
-rw-r--r-- | moon_forming/Dockerfile | 6 | ||||
-rw-r--r-- | moon_forming/README.md | 7 | ||||
-rw-r--r-- | moon_forming/config_moon.sh (renamed from moon_forming/run.sh) | 4 | ||||
-rw-r--r-- | moon_forming/switch.sh | 19 |
4 files changed, 27 insertions, 9 deletions
diff --git a/moon_forming/Dockerfile b/moon_forming/Dockerfile index ca0eba76..74616c89 100644 --- a/moon_forming/Dockerfile +++ b/moon_forming/Dockerfile @@ -1,11 +1,11 @@ FROM python:3 WORKDIR /usr/src/app -RUN pip install --no-cache-dir --upgrade requests pyyaml python_moonutilities python_moondb python_moonclient +RUN pip install --no-cache-dir --upgrade requests pytest pyyaml python_moonutilities python_moondb python_moonclient -ENV POPULATE_ARGS "-v" +ENV COMMAND "config" ADD . /root WORKDIR /root -CMD sh /root/run.sh ${POPULATE_ARGS}
\ No newline at end of file +CMD /bin/bash /root/switch.sh ${COMMAND} diff --git a/moon_forming/README.md b/moon_forming/README.md index cc08f676..9b755d96 100644 --- a/moon_forming/README.md +++ b/moon_forming/README.md @@ -39,6 +39,9 @@ kubectl delete -f $MOON_HOME/tools/moon_kubernetes/templates/moon_forming.yaml kubectl create -f $MOON_HOME/tools/moon_kubernetes/templates/moon_forming.yaml ``` +## Functional tests - - +```bash +cd $MOON_HOME/moon_manager +bash ../tests/functional/run_tests_for_component.sh +``` diff --git a/moon_forming/run.sh b/moon_forming/config_moon.sh index d731cb17..0a55898f 100644 --- a/moon_forming/run.sh +++ b/moon_forming/config_moon.sh @@ -37,7 +37,3 @@ while ! python -c "import requests; req = requests.get('http://manager:8082')" 2 done echo "." echo "Manager (http://manager:8082) is up." - -#for i in /data/*.py ; do -# moon_populate_values $populate_args --consul-host=consul --consul-port=8500 $i -#done diff --git a/moon_forming/switch.sh b/moon_forming/switch.sh new file mode 100644 index 00000000..adb1ebe9 --- /dev/null +++ b/moon_forming/switch.sh @@ -0,0 +1,19 @@ +#!/usr/bin/env bash + +CMD=$1 + +echo "COMMAND IS ${CMD}" + +if [ "${CMD}" = "functest" ]; then + echo "FUNCTIONAL TESTS" + ls -l /data + ls -l /data/tests + sh /data/tests/functional_pod/run_functional_tests.sh +#elif [ $CMD == "unittest" ]; then +# sh /data/tests/functional_pod/run_functional_tests.sh +else + echo "CONFIGURATION" + bash config_moon.sh +fi + +echo "<END OF JOB>"
\ No newline at end of file |