Skip to content

Last gitlab ci

Last gitlab ci #3771

Workflow file for this run

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:
runs-on: ubuntu-24.04
timeout-minutes: 20
container:
image: domjudge/gitlabci:24.04
services:
sqlserver:
image: mariadb
ports:
- 3306:3306
env:
MYSQL_ROOT_PASSWORD: root
MYSQL_USER: domjudge
MYSQL_PASSWORD: domjudge
options: --health-cmd="healthcheck.sh --connect --innodb_initialized" --health-interval=10s --health-timeout=5s --health-retries=3
strategy:
matrix:
PHPVERSION: [8.1]
TEST: [Unit, E2E]
CRAWL_SHADOW_MODE: [0]
SQL_OPTIONS: [--health-cmd="healthcheck.sh --connect --innodb_initialized"]
SQL: [mariadb]
#include:
# - PHPVERSION: 8.4
# TEST: Unit
# SQL: mysql
# SQL_OPTIONS: --health-cmd="mysqladmin ping"
steps:
- uses: actions/checkout@v4
- 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: Run the unit tests
run: .github/jobs/unit-tests.sh ${{ matrix.PHPVERSION }} ${{ matrix.TEST }}
- name: Upload artifact for debugging
uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
name: unit-test-output
path: /tmp/artifacts
- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: ${{ !cancelled() }}
with:
files: |
unit-tests.xml
check-static-codecov:
runs-on: ubuntu-latest
steps:
- name: Keep the original job as its 'required'
run: exit 0