Closed gshif closed 4 years ago
We can break it further if needs to be:
Here is one of the ways to run tests against cloud test environments locally in case your local python version is not 3.8.2:
docker build -f Dockerfile -t litmus_1 .
docker run --entrypoint "bash" -v <local dir>:/Litmus/result -it litmus_1
gs-1
user the name of the cluster and if want to run test list, use --tests-list
instead of --tests
option and provide a path to a test list.
python litmus_run_master.py --etcd http://etcd.gs-1.svc.cluster.local:2379 --tasks http://tasks-main.gs-1.svc.cluster.local:8276 --gateway http://gateway-main.gs-1.svc.cluster.local:9999 --queryd http://queryd-main.gs-1.svc.cluster.local:8093 --transpilerde http://transpilerde-main.gs-1.svc.cluster.local:8098 --namespace gs-1 --storage http://storage.gs-1.svc.cluster.local:6060 --storage-controller http://storage-controller.gs-1.svc.cluster.local:6060 --kubecluster dex@acceptance --kubeconf ~/.kube/config --tests src/cloud/rest_api/storage/test_delete_with_predicate.py
Running tests against cloud environments using docker container. Using above steps from above, build docker image
gs-1
use the name of your cluster:
docker run --rm -e ETCD_HOST=http://etcd.gs-1.svc.cluster.local:2379 -e TASKS_HOST=http://tasks-main.gs-1.svc.cluster.local:8276 -e GATEWAY_HOST=http://gateway-main.gs-1.svc.cluster.local:9999 -e QUERYD_HOST=http://queryd-main.gs-1.svc.cluster.local:8093 -e TRANSPILERDE_HOST=http://transpilerde-main.gs-1.svc.cluster.local:8098 -e NAMESPACE=gs-1 -e KUBE_CONFIG=~/.kube/config -e STORAGE_HOST=http://storage.gs-1.svc.cluster.local:6060 -e STORAGE_CONTROLLER_HOST=http://storage-controller.gs-1.svc.cluster.local:6060 -e KUBE_CLUSTER=dex@acceptance -e ONE_TEST=src/cloud/rest_api/storage/test_delete_with_predicate.py -e NO_ETCD_QUERY=--no-etcd-query -v ~/Pictures:/Litmus/result litmus_3
Based on our conversation: @Nlyandres is taking running all of the test suites against cloud test environment by running litmus locally @dangilkerson is taking running all of the tests suites against cloud test environment by running litmus container
I am going to put steps shortly for running tests in oss.
After making changes to Litmus to run python 3.8.2/pytest 5.4 (+ other required python modules), the first task is to run all of the test suites and identify the failures. The next step would be to fix the issues. Deploying cloud test environment can be done in a few ways:
fenv
kubone
(The easiest way, but takes a lot of comp power, since you have to run docker + kubernetes locally)Need to run tests in 2 ways(See README.md for running tests in the local dev environment or in the cloud using Litmus container or locally.)