Skip to content

Commit 9bf321f

Browse files
committed
Add a GitHub Actions Workflow to perform unit tests
1 parent c450494 commit 9bf321f

2 files changed

Lines changed: 26 additions & 0 deletions

File tree

.github/workflows/unit-tests.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: unit tests
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
perform-unit-tests:
10+
runs-on: ubuntu-latest
11+
steps:
12+
# Checkout the code
13+
- uses: actions/checkout@v5
14+
15+
# Install .NET SDK
16+
- name: Setup .NET SDK
17+
uses: actions/setup-dotnet@v5
18+
with:
19+
dotnet-version: 10.0.x
20+
21+
# Perform unit tests
22+
- name: Perform unit tests
23+
run: dotnet test --project ./UserSecretsExtension.Test --output detailed

global.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,8 @@
33
"rollForward": "latestMinor",
44
"version": "10.0.0",
55
"allowPrerelease": false
6+
},
7+
"test": {
8+
"runner": "Microsoft.Testing.Platform"
69
}
710
}

0 commit comments

Comments
 (0)