Skip to content

Mutation testing

Mutation testing #7

name: Mutation testing
on:
schedule:
- cron: "17 3 * * 1"
workflow_dispatch:
permissions:
contents: read
jobs:
dbwriter:
name: DbWriter mutation testing
runs-on: ubuntu-24.04
timeout-minutes: 60
steps:
- name: Check out repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Set up .NET
uses: actions/setup-dotnet@9a946fdbd5fb07b82b2f5a4466058b876ab72bb2 # v5.3.0
with:
dotnet-version: |
8.0.413
9.0.301
- name: Cache Stryker tool and NuGet packages
id: mutation-cache
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
with:
path: |
~/.dotnet/tools
~/.nuget/packages
key: ${{ runner.os }}-mutation-stryker-4.14.0-${{ hashFiles('**/packages.lock.json', 'global.json') }}
- name: Restore
run: dotnet restore CodeIndex.sln --locked-mode
- name: Install Stryker.NET
if: steps.mutation-cache.outputs.cache-hit != 'true'
run: dotnet tool update --global dotnet-stryker --version 4.14.0
- name: Run DbWriter mutation tests
run: dotnet stryker --config-file stryker-config.json