Last gitlab ci #3567
Workflow file for this run
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: Unit tests | |
| # We can speedup with: https://github.com/actions/cache | |
| on: | |
| push: | |
| merge_group: | |
| pull_request: | |
| branches: | |
| - main | |
| - '[0-9]+.[0-9]+' | |
| jobs: | |
| unit-tests: | |
| container: | |
| image: domjudge/gitlabci:24.04 | |
| options: --privileged --cgroupns=host --init | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| PHPVERSION: [8.1] | |
| TEST: [UNIT] | |
| services: | |
| sqlserver: | |
| image: mariadb | |
| ports: | |
| - 3306:3306 | |
| env: | |
| MYSQL_ROOT_PASSWORD: root | |
| options: --health-cmd="healthcheck.sh --connect --innodb_initialized" --health-interval=10s --health-timeout=5s --health-retries=3 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Run the unit tests | |
| run: .github/jobs/unit-tests.sh ${{ matrix.PHPVERSION }} ${{ matrix.TEST }} | |
| #- name: Download latest codecov upload script | |
| # run: wget https://codecov.io/bash -O newcodecov | |
| #- name: Detect changes to manually verify | |
| # run: diff newcodecov .github/jobs/uploadcodecov.sh | |
| #- name: Publish Test Results | |
| # uses: EnricoMi/publish-unit-test-result-action@v2 | |
| # if: always() | |
| # with: | |
| # files: | | |
| # test-results/**/*.xml | |
| - name: Upload artifact for debugging | |
| uses: actions/upload-artifact@v3 | |
| with: | |
| name: unit-test-output | |
| path: /tmp/artifacts | |
| #.unit_job: | |
| # script: | |
| # - set -eux | |
| # - if [ -z ${PHPVERSION+x} ]; then export PHPVERSION=8.1; fi | |
| # - if [ -z ${TEST+x} ]; then export TEST="UNIT"; fi | |
| # - if [ "$TEST" = "UNIT" ] && [ "$CRAWL_SHADOW_MODE" != "0" ]; then exit 0; fi | |
| # - if [ "$TEST" = "E2E" ] && [ "$CRAWL_SHADOW_MODE" != "0" ] && [ "$CI_COMMIT_BRANCH" != "main" ]; then exit 0; fi | |
| # - export CRAWL_SHADOW_MODE | |
| # - ./gitlab/unit-tests.sh $PHPVERSION $TEST | |
| # artifacts: | |
| # when: always | |
| # paths: | |
| # - unit-tests.xml | |
| # - coverage-html | |
| # - deprecation.txt | |
| # - duration | |
| # - gitlabartifacts | |
| # reports: | |
| # junit: | |
| # - unit-tests.xml | |
| # | |
| #run unit tests: | |
| # only: | |
| # - main | |
| # - /^[0-9].[0-9]$/ | |
| # extends: [.mariadb_job,.phpsupported_job,.unit_job] | |
| # | |
| #run unit tests (PR): | |
| # except: | |
| # - main | |
| # - /^[0-9].[0-9]$/ | |
| # extends: [.mariadb_job,.phpsupported_job_pr,.unit_job] | |
| # | |
| #run unit tests (MySQL): | |
| # only: | |
| # - main | |
| # - /^[0-9].[0-9]$/ | |
| # extends: [.mysql_job,.unit_job] | |
| # parallel: | |
| # matrix: | |
| # - TEST: ["E2E","Unit"] | |
| # CRAWL_SHADOW_MODE: ["0"] |