forked from dotnet/docfx
-
Notifications
You must be signed in to change notification settings - Fork 0
79 lines (67 loc) · 2.11 KB
/
ci.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: ci
on:
pull_request:
branches: [ main, feature/*, hotfix/* ]
push:
branches: [ main, feature/*, hotfix/* ]
workflow_dispatch:
inputs:
seed:
description: 'Enter an integer value between 0 and 2147483647.'
type: number
required: true
default: 0
env:
seed: ${{ inputs.seed || github.run_number }}
NO_COLOR: true
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-latest, macos-latest, ubuntu-latest]
steps:
- uses: actions/checkout@v4
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{ github.event.pull_request.head.repo.full_name }}
lfs: true
- uses: ./.github/actions/build
- run: npm run lint
shell: bash
working-directory: templates
- run: npm test
shell: bash
working-directory: templates
- name: Install Chromium Headless Shell
shell: pwsh
working-directory: src/docfx/bin/Release/net8.0
run: |
$env:PLAYWRIGHT_NODEJS_PATH = (Get-Command node).Path
./playwright.ps1 install chromium --only-shell
- run: dotnet test -c Release -f net8.0 --no-build --consoleLoggerParameters:"Summary;Verbosity=Minimal" -- --seed ${{ env.seed }}
id: test-net80
- uses: codecov/codecov-action@v5
if: matrix.os == 'ubuntu-latest'
with:
fail_ci_if_error: false
token: ${{ secrets.CODECOV_TOKEN }}
- run: echo "DOTNET_DbgEnableMiniDump=1" >> $GITHUB_ENV
if: matrix.os == 'ubuntu-latest'
- name: Upload Logs
uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
name: logs-${{ matrix.os }}
path: |
msbuild.binlog
test/**/TestResults/*.log
test/**/TestResults/*.trx
test/**/TestResults/*.html
test/**/TestResults/*.ctrf
- uses: actions/upload-artifact@v4
if: ${{ failure() && matrix.os == 'ubuntu-latest' }}
with:
name: dump
path: /tmp/coredump*