-
-
Notifications
You must be signed in to change notification settings - Fork 119
53 lines (45 loc) · 1.14 KB
/
run_tests.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
name: Tests
on:
workflow_call: {}
jobs:
prepare:
name: Find Tests 🔍
runs-on: ubuntu-latest
outputs:
tests: ${{ steps.tests.outputs.tests }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Nix ❄️
uses: ./.github/actions/install-nix
- name: Find Tests 🔍
id: tests
run: |
find tests -name '*.Tests.ps1' -print0 | perl -pe 's|(.*?)\x0|"\1",|g;s|,$||;s|(.*)|tests=[\1]|' >> $GITHUB_OUTPUT
tests:
name: Test 🧪
needs:
- prepare
strategy:
fail-fast: false
matrix:
test: ${{ fromJSON(needs.prepare.outputs.tests) }}
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Download Tarball 📥
uses: actions/download-artifact@v4
with:
name: tarball
- name: Setup WSL 🐧
run: |
wsl --update
wsl --version
- name: Execute Test 🧪
shell: pwsh
run: Invoke-Pester -Output Detailed ${{ matrix.test }}