From 3e722a9d8b7f88f7b8fb0ccd55c8ec8cef3900f3 Mon Sep 17 00:00:00 2001 From: youben11 Date: Tue, 14 Mar 2023 10:10:33 +0100 Subject: [PATCH] ci: enable minimal tests on PRs --- .github/workflows/compiler_build_and_test_cpu.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/compiler_build_and_test_cpu.yml b/.github/workflows/compiler_build_and_test_cpu.yml index a68ae4ca5..8e0b77b25 100644 --- a/.github/workflows/compiler_build_and_test_cpu.yml +++ b/.github/workflows/compiler_build_and_test_cpu.yml @@ -98,6 +98,14 @@ jobs: export COMPILER_BUILD_DIRECTORY=/build make whl + - name: Enable complete tests on push to main + if: github.ref == 'refs/heads/main' + run: echo "MINIMAL_TESTS=OFF" >> $GITHUB_ENV + + - name: Enable minimal tests otherwise + if: github.ref != 'refs/heads/main' + run: echo "MINIMAL_TESTS=ON" >> $GITHUB_ENV + - name: Test compiler uses: addnab/docker-run-action@v3 with: @@ -123,7 +131,7 @@ jobs: cd /concrete/compilers/concrete-compiler/compiler sed "s/pytest/python -m pytest/g" -i Makefile mkdir -p /tmp/concrete_compiler/gpu_tests/ - make DATAFLOW_EXECUTION_ENABLED=ON CCACHE=ON Python3_EXECUTABLE=$(which python3) BUILD_DIR=/build run-tests run-end-to-end-dataflow-tests + make MINIMAL_TESTS=${{ env.MINIMAL_TESTS }} DATAFLOW_EXECUTION_ENABLED=ON CCACHE=ON Python3_EXECUTABLE=$(which python3) BUILD_DIR=/build run-tests run-end-to-end-dataflow-tests chmod -R ugo+rwx /tmp/KeySetCache - name: Archive python package