Skip to content

Commit a333254

Browse files
committed
(GH-2028) Added unit test for GH Actions
1 parent 574ccc2 commit a333254

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

.github/workflows/build.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ on:
1111
env:
1212
DOTNET_ROLL_FORWARD_ON_NO_CANDIDATE_FX: 2
1313
ENABLED_MULTI_STAGE_BUILD: true
14+
ENABLED_UNIT_TESTS: true
1415

1516
jobs:
1617
build:
@@ -47,3 +48,34 @@ jobs:
4748
name: storage
4849
path: ${{ github.workspace }}/artifacts
4950
name: 'Upload Package'
51+
52+
test:
53+
name: Unit Test
54+
runs-on: ${{ matrix.os }}
55+
env:
56+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
57+
strategy:
58+
matrix:
59+
os: [windows-latest, ubuntu-latest, macos-latest]
60+
fail-fast: false
61+
62+
steps:
63+
- uses: actions/checkout@v2
64+
- name: Fetch all history for all tags and branches
65+
run: |
66+
git fetch --prune --unshallow
67+
- name: Cache tools
68+
id: cache-tools
69+
uses: actions/cache@v1
70+
with:
71+
path: tools
72+
key: ${{ runner.os }}-tools-${{ hashFiles('build.cake') }}
73+
- name: Cache dotnet
74+
id: cache-dotnet
75+
uses: actions/cache@v1
76+
with:
77+
path: .dotnet
78+
key: ${{ runner.os }}-dotnet-${{ hashFiles('build.config') }}
79+
- name: '[Run Test]'
80+
shell: pwsh
81+
run: ./build.ps1 -target Test

0 commit comments

Comments
 (0)