1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-05-31 01:16:01 +02:00

fix(ci): update config to make GHA reporting be better

This commit is contained in:
Christopher Kolstad 2025-05-16 14:51:45 +02:00
parent a08db953b8
commit 8afaf7e88b
No known key found for this signature in database
3 changed files with 21 additions and 16 deletions

View File

@ -18,7 +18,7 @@ jobs:
name: build
permissions:
contents: read
# Needed for the github-reporter from vite to make comments on PRs
# Needed for the github-reporter from vitest to make comments on PRs
pull-requests: write
services:
# Label used to access the service container

View File

@ -9,14 +9,16 @@ on:
- website/**
- frontend/**
- coverage/**
pull_request:
paths-ignore:
- website/**
- frontend/**
- coverage/**
jobs:
coverage:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20.x]
services:
# Label used to access the service container
postgres:
@ -35,7 +37,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
- name: Use Node.js 22
uses: actions/setup-node@v4
with:
node-version: 22.x

View File

@ -5,17 +5,20 @@ export default defineConfig({
globals: true,
globalSetup: ['./src/test-setup.ts'],
setupFiles: ['./src/test/errorWithMessage.ts'],
reporters: [
[
'junit',
{
suiteName: 'Unleash Unit Tests',
outputFile: 'reports/jest-junit.xml',
classnameTemplate: '{filename} - {filepath}',
},
],
['default'],
],
reporters: process.env.GITHUB_ACTIONS
? [
['dot'],
[
'junit',
{
suiteName: 'Unleash Unit Tests',
outputFile: 'reports/jest-junit.xml',
classnameTemplate: '{filename} - {filepath}',
},
],
['github-actions'],
]
: [['default']],
testTimeout: 30000,
exclude: [
...configDefaults.exclude,