-
Notifications
You must be signed in to change notification settings - Fork 2
35 lines (32 loc) · 1.04 KB
/
build-main.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: Build-Main
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build-debug:
name: Build and run tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: Cysharp/Actions/.github/actions/setup-dotnet@main
- run: dotnet build -c Debug -p:DefineConstants=RUNNING_IN_CI
- run: dotnet pack ./src/Multicaster/Multicaster.csproj -c Debug --no-build -p:IncludeSymbols=true -p:SymbolPackageFormat=snupkg
- run: dotnet test -c Debug --no-build
- uses: Cysharp/Actions/.github/actions/upload-artifact@main
with:
name: nuget
path: ./src/Multicaster/bin/Debug/*.*nupkg
retention-days: 1
test-release-build:
name: Run tests using Release build
needs: [ build-debug ]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: Cysharp/Actions/.github/actions/setup-dotnet@main
- run: dotnet build -c Release -p:DefineConstants=RUNNING_IN_CI
- run: dotnet test -c Release --no-build