-
Notifications
You must be signed in to change notification settings - Fork 26
48 lines (46 loc) · 1.32 KB
/
dotnet.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
name: dotnet
on:
push:
branches: [master]
paths:
- "dotnet/**"
pull_request:
paths:
- "dotnet/**"
workflow_dispatch:
env:
LAUNCHABLE_TOKEN: ${{ secrets.LAUNCHABLE_TOKEN_DOTNET }}
LAUNCHABLE_DEBUG: 1
LAUNCHABLE_REPORT_ERROR: 1
jobs:
tests:
runs-on: ubuntu-latest
defaults:
run:
working-directory: dotnet
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- name: Set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Setup .NET Core SDK
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.100
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install wheel setuptools_scm
pip install launchable
- run: "launchable verify"
- name: Record commits and build
run: 'launchable record build --name "$GITHUB_RUN_ID" --source ..'
- name: Start session
run: 'launchable record session --build "$GITHUB_RUN_ID" > test_session.txt'
- name: Run test
run: dotnet test --logger:"nunit;LogFilePath=test-result.xml"
- name: Record test results
run: launchable record test --session "$(cat test_session.txt)" dotnet test-result.xml
if: always()