Regression Tests #11091
This file contains hidden or 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: Regression Tests | |
| on: | |
| schedule: | |
| - cron: "0 0/3 * * *" | |
| workflow_dispatch: | |
| inputs: | |
| # Pytest - manual trigger inpu | |
| test-suites: | |
| description: "Pytest: optional filenames; empty runs all Pytest suites. See .github/REGRESSION-TESTS.md for details. Example: connection_test,eval_test" | |
| required: false | |
| default: "" | |
| type: string | |
| test-cases: | |
| description: "Pytest: optional node ID regex. Example: test_golang_asynq_script|test_shared_read_buffer_overflow_copy_metric" | |
| required: false | |
| default: "" | |
| type: string | |
| iterations: | |
| description: "Pytest: optional number of iterations. Default: 1. Example: 12" | |
| required: false | |
| default: "1" | |
| type: string | |
| # GoogleTest - manual trigger inputs. | |
| gtest-suites: | |
| description: "GoogleTest: manual runs only; optional targets, empty runs every target. Example: dfly_core_test,redis_parser_test" | |
| required: false | |
| default: "" | |
| type: string | |
| gtest-cases: | |
| description: "GoogleTest: optional --gtest_filter. Example: StringMapTest.*:DashTest.*" | |
| required: false | |
| default: "" | |
| type: string | |
| gtest-iterations: | |
| description: "GoogleTest: optional number of iterations. Default: 1. Example: 12" | |
| required: false | |
| default: "1" | |
| type: string | |
| # Common inputs. | |
| max-tests-run-time: | |
| description: "Common: combined time limit (minutes) for Pytest and GoogleTest runs; Default: 360" | |
| required: false | |
| default: "360" | |
| type: string | |
| continue-on-test-failure: | |
| description: "Common: failure handling for Pytest and GoogleTest; true completes iterations, archives failed Pytest logs, and deletes clean logs." | |
| required: false | |
| default: false | |
| type: boolean | |
| jobs: | |
| build: | |
| if: github.repository == 'dragonflydb/dragonfly' | |
| strategy: | |
| fail-fast: ${{ github.event_name != 'workflow_dispatch' || !inputs.continue-on-test-failure }} | |
| matrix: | |
| # Test of these containers | |
| container: ["ubuntu-dev:24"] | |
| proactor: [Uring] | |
| build-type: [Debug, Release] | |
| runner: [ubuntu-latest, [self-hosted, linux, ARM64]] | |
| enable_resp_io_loop_v2: [false, true] | |
| runs-on: ${{ matrix.runner }} | |
| permissions: | |
| id-token: write | |
| contents: read | |
| actions: write # To allow deleting cache | |
| container: | |
| image: ghcr.io/romange/${{ matrix.container }} | |
| options: --security-opt seccomp=unconfined --sysctl "net.ipv6.conf.all.disable_ipv6=0" | |
| volumes: | |
| - /var/crash:/var/crash | |
| - /:/hostroot | |
| - /mnt:/mnt | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| submodules: true | |
| - name: Init Manual runs | |
| if: github.event_name == 'workflow_dispatch' | |
| shell: bash | |
| env: | |
| ITERATIONS_INPUT: ${{ inputs.iterations || '1' }} | |
| TEST_SUITES_INPUT: ${{ inputs.test-suites || '' }} | |
| TEST_CASES_INPUT: ${{ inputs.test-cases || '' }} | |
| GTEST_SUITES_INPUT: ${{ inputs.gtest-suites || '' }} | |
| GTEST_ITERATIONS_INPUT: ${{ inputs.gtest-iterations || '' }} | |
| MAX_TESTS_RUN_TIME_INPUT: ${{ inputs.max-tests-run-time || '' }} | |
| CONTINUE_ON_TEST_FAILURE_INPUT: ${{ inputs.continue-on-test-failure || 'false' }} | |
| run: | | |
| .github/scripts/run-regression-tests-helper.sh validate | |
| - name: Print environment info | |
| run: | | |
| cat /proc/cpuinfo | |
| ulimit -a | |
| env | |
| lsblk -l | |
| - name: Build Dragonfly | |
| uses: ./.github/actions/builder | |
| with: | |
| enable-ccache: 'true' | |
| ccache-save: 'true' | |
| enable-deps-cache: 'true' | |
| build-type: ${{matrix.build-type}} | |
| cache-key-suffix: 'df_common_bin' | |
| c-compiler: gcc | |
| cxx-compiler: g++ | |
| targets: 'dragonfly' | |
| - name: Authenticate to AWS | |
| if: github.repository_owner == 'dragonflydb' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) | |
| uses: aws-actions/configure-aws-credentials@v6 | |
| with: | |
| role-to-assume: ${{ secrets.AWS_CI_S3_ROLE_ARN }} | |
| aws-region: us-east-1 | |
| - name: Run regression tests action | |
| uses: ./.github/actions/regression-tests | |
| with: | |
| dfly-executable: dragonfly | |
| gspace-secret: ${{ secrets.GSPACES_BOT_DF_BUILD }} | |
| build-folder-name: build | |
| filter: ${{ matrix.build-type == 'Release' && 'not debug_only' || 'not opt_only' }} | |
| test-suites: ${{ inputs.test-suites || '' }} | |
| test-cases: ${{ inputs.test-cases || '' }} | |
| iterations: ${{ inputs.iterations || '1' }} | |
| max-tests-run-time: ${{ inputs.max-tests-run-time || '' }} | |
| gtest-suites: ${{ inputs.gtest-suites || '' }} | |
| gtest-cases: ${{ inputs.gtest-cases || '' }} | |
| gtest-iterations: ${{ inputs.gtest-iterations || '' }} | |
| run-gtests: 'true' | |
| continue-on-test-failure: ${{ inputs.continue-on-test-failure || 'false' }} | |
| df-runtime-flags: enable_resp_io_loop_v2=${{ matrix.enable_resp_io_loop_v2 }} | |
| s3-bucket: ${{ secrets.S3_REGTEST_BUCKET }} | |
| junit-s3-bucket: ${{ secrets.S3_REGTEST_BUCKET }} | |
| aws-role-to-assume: ${{ secrets.AWS_CI_S3_ROLE_ARN }} | |
| - name: Upload logs on failure | |
| if: failure() | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: logs | |
| path: /tmp/failed/* | |
| lint-test-chart: | |
| if: github.repository == 'dragonflydb/dragonfly' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: ./.github/actions/lint-test-chart |