run_tests #215
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: run_tests | |
on: workflow_dispatch | |
jobs: | |
run_tests: | |
name: Run Tests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Cache python | |
uses: actions/cache@v3 | |
id: cache-python | |
with: | |
path: ~/venv/qa | |
key: python-${{ hashFiles('tests/image/requirements.txt') }} | |
- name: Install python dependencies | |
run: | | |
set -x | |
python3 -m venv ~/venv/qa | |
~/venv/qa/bin/pip3 install -U -r ./tests/image/requirements.txt | |
if: | | |
steps.cache-python.outputs.cache-hit != 'true' | |
- name: Setup required Ubuntu packages | |
run: | | |
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 8919F6BD2B48D754 | |
echo "deb https://packages.clickhouse.com/deb stable main" | sudo tee /etc/apt/sources.list.d/clickhouse.list | |
sudo apt-get update | |
sudo apt-get install -y conntrack clickhouse-client | |
- uses: medyagh/setup-minikube@master | |
with: | |
driver: docker | |
container-runtime: containerd | |
kubernetes-version: v1.25.3 | |
cpus: max | |
memory: max | |
- name: Run Tests | |
run: | | |
source ~/venv/qa/bin/activate | |
set -x | |
# bash -xe ./deploy/prometheus/create-prometheus.sh | |
# bash -xe ./deploy/minio/install-minio-operator.sh | |
# bash -xe ./deploy/minio/install-minio-tenant.sh | |
# bash -xe /deploy/grafana/grafana-with-grafana-operator/install-grafana-operator.sh | |
# bash -xe /deploy/grafana/grafana-with-grafana-operator/install-grafana-with-operator.sh | |
# docker compose -f ./tests/docker-compose/docker-compose.yml pull runner | |
# ~/venv/qa/bin/python3 ./tests/regression.py --only "/regression/e2e.test_operator/*" --trim-results on --debug --log ./tests/raw.log | |
# bash ./tests/e2e/run_tests_parallel.sh | |
sudo ln -snvf ~/venv/qa/bin/tfs /bin/tfs | |
~/venv/qa/bin/python3 ./tests/regression.py --only "/regression/e2e.test_operator/*" --trim-results on --debug --native --log ./tests/raw.log | |
~/venv/qa/bin/tfs --debug --no-colors transform compact ./tests/raw.log ./tests/compact.log | |
~/venv/qa/bin/tfs --debug --no-colors transform nice ./tests/raw.log ./tests/nice.log.txt | |
~/venv/qa/bin/tfs --debug --no-colors transform short ./tests/raw.log ./tests/short.log.txt | |
~/venv/qa/bin/tfs --debug --no-colors report results -a "${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}/" ./tests/raw.log - --confidential --copyright "Altinity LTD" --logo ./tests/altinity.png | ~/venv/qa/bin/tfs --debug --no-colors document convert > ./tests/report.html | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: testflows-logs | |
path: | | |
tests/*.log | |
tests/*.log.txt | |
if-no-files-found: error | |
retention-days: 7 | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: testflows-report | |
path: | | |
tests/report.html | |
if-no-files-found: error | |
retention-days: 7 |