-
Notifications
You must be signed in to change notification settings - Fork 2
51 lines (46 loc) · 1.31 KB
/
build_test.yml
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: CrispyCollab Build and Test
on:
push:
branches:
- main
workflow_dispatch:
jobs:
build_test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal --results-directory "TestResults"
- name: Upload Test Results
uses: actions/upload-artifact@v3
with:
name: Test-Results
path: TestResults
# Use always() to always run this step to publish test results when there are test failures
if: always()
retention-days: 1
- name: Publish
run: dotnet publish --configuration release --output './published-app' ${{ github.workspace }}/Source/Web/Server/Web.Server.csproj
- name: Upload Publish Artifact
uses: actions/upload-artifact@v4
with:
name: Published-Artifacts
path: './published-app'
deploy_dev:
needs: build_test
runs-on: ubuntu-latest
environment: dev
steps:
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: Published-Artifacts
path: './published-app'