mirror of
https://github.com/edgegamers/Gangs.git
synced 2025-12-06 04:42:56 -08:00
Matrix versions
This commit is contained in:
23
.github/workflows/dotnet.yml
vendored
23
.github/workflows/dotnet.yml
vendored
@@ -1,6 +1,3 @@
|
||||
# This workflow will build a .NET project
|
||||
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
|
||||
|
||||
name: .NET
|
||||
|
||||
on:
|
||||
@@ -12,15 +9,31 @@ jobs:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
dotnet-version: [6.0.x, 7.0.x, 8.0.x, 9.0.x] # Test on multiple .NET versions
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v4
|
||||
with:
|
||||
dotnet-version: 8.0.x
|
||||
dotnet-version: ${{ matrix.dotnet-version }}
|
||||
|
||||
- name: Cache .NET packages
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ~/.nuget/packages
|
||||
key: ${{ runner.os }}-nuget-${{ hashFiles('**/*.csproj') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-nuget-
|
||||
|
||||
- name: Restore dependencies
|
||||
run: dotnet restore
|
||||
|
||||
- name: Build
|
||||
run: dotnet build --no-restore
|
||||
run: dotnet build --no-restore --configuration Release
|
||||
|
||||
- name: Test
|
||||
run: dotnet test GangsTest --no-build --verbosity normal
|
||||
|
||||
Reference in New Issue
Block a user