diff options
Diffstat (limited to 'csit/run-project-csit.sh')
-rwxr-xr-x | csit/run-project-csit.sh | 36 |
1 files changed, 30 insertions, 6 deletions
diff --git a/csit/run-project-csit.sh b/csit/run-project-csit.sh index 678bfe2a..8d467ade 100755 --- a/csit/run-project-csit.sh +++ b/csit/run-project-csit.sh @@ -42,12 +42,19 @@ function docker_stats(){ function setup_clamp() { export ROBOT_FILES="policy-clamp-test.robot" - export TEST_ENV="docker" source "${WORKSPACE}"/compose/start-compose.sh policy-clamp-runtime-acm sleep 30 bash "${SCRIPTS}"/wait_for_rest.sh localhost "${ACM_PORT}" } +function setup_clamp_replica() { + export ROBOT_FILES="policy-clamp-test.robot" + export TEST_ENV="docker" + source "${WORKSPACE}"/compose/start-acm-replica.sh 2 + sleep 30 + bash "${SCRIPTS}"/wait_for_rest.sh localhost "${ACM_PORT}" +} + function setup_api() { export ROBOT_FILES="api-test.robot api-slas.robot" source "${WORKSPACE}"/compose/start-compose.sh api --grafana @@ -73,7 +80,7 @@ function setup_apex() { function setup_apex_postgres() { export ROBOT_FILES="apex-pdp-test.robot" - source "${WORKSPACE}"/compose/start-postgres-tests.sh 1 + source "${WORKSPACE}"/compose/start-postgres-tests.sh apex-pdp 1 sleep 10 bash "${SCRIPTS}"/wait_for_rest.sh localhost ${PAP_PORT} bash "${SCRIPTS}"/wait_for_rest.sh localhost ${APEX_PORT} @@ -134,6 +141,13 @@ function setup_xacml_pdp() { bash "${SCRIPTS}"/wait_for_rest.sh localhost "${XACML_PORT}" } +function setup_xacml_pdp_postgres() { + export ROBOT_FILES="xacml-pdp-test.robot" + source "${WORKSPACE}"/compose/start-postgres-tests.sh xacml-pdp 1 + sleep 10 + bash "${SCRIPTS}"/wait_for_rest.sh localhost "${XACML_PORT}" +} + function setup_drools_pdp() { export ROBOT_FILES="drools-pdp-test.robot" source "${WORKSPACE}"/compose/start-compose.sh drools-pdp @@ -173,6 +187,10 @@ function set_project_config() { setup_clamp ;; + clamp-replica | policy-clamp-replica) + setup_clamp_replica + ;; + api | policy-api) setup_api ;; @@ -186,21 +204,25 @@ function set_project_config() { ;; apex-pdp-postgres | policy-apex-pdp-postgres) - setup_apex + setup_apex_postgres ;; apex-pdp-medium | policy-apex-pdp-medium) - setup_apex + setup_apex_medium ;; apex-pdp-large | policy-apex-pdp-large) - setup_apex + setup_apex_large ;; xacml-pdp | policy-xacml-pdp) setup_xacml_pdp ;; + xacml-pdp-postgres | policy-xacml-pdp-postgres) + setup_xacml_pdp_postgres + ;; + drools-pdp | policy-drools-pdp) setup_drools_pdp ;; @@ -242,6 +264,8 @@ export PROJECT="${1}" export ROBOT_LOG_DIR=${WORKSPACE}/csit/archives/${PROJECT} export SCRIPTS="${WORKSPACE}/csit/resources/scripts" export ROBOT_FILES="" +# always 'docker' if running docker compose +export TEST_ENV="docker" cd "${WORKSPACE}" @@ -270,7 +294,7 @@ unset http_proxy https_proxy export ROBOT_FILES -# use a separate script to build a CSIT docker image, to containerize the test run +# use a separate script to build a CSIT docker image, to isolate the test run if [ "${2}" == "--skip-build-csit" ]; then echo "Skipping build csit robot image" else |