-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (40 loc) · 1.38 KB
/
pr.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
name: PowerAutomate.Desktop.Modules-PR
on:
pull_request:
branches:
- main
env:
CONFIGURATION: "Release"
ENVIRONMENT: "Production"
jobs:
build:
runs-on: windows-latest
steps:
- name: Checkout
if: ${{ success() }}
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install Power Automate for desktop
if: ${{ success() }}
run: |
Invoke-WebRequest -Uri https://go.microsoft.com/fwlink/?linkid=2164365 -OutFile PADSetup.exe
.\PADSetup.exe -Install -AcceptEULA -Silent
Start-Sleep -Seconds 10
$processName = "PADSetup"
do {
Write-Host "Waiting for process to exit..."
Start-Sleep -Seconds 10
} while (Get-Process -Name $processName -ErrorAction SilentlyContinue)
- name: Setup MSBuild
if: ${{ success() }}
uses: microsoft/[email protected]
- name: Restore solution
if: ${{ success() }}
run: msbuild src\PowerAutomate.Desktop.sln -target:restore -property:Configuration=${{ env.CONFIGURATION }} -property:Environment=${{ env.ENVIRONMENT }}
- name: Build solution filter
if: ${{ success() }}
run: msbuild src\build.slnf -target:rebuild -property:Configuration=${{ env.CONFIGURATION }} -property:Environment=${{ env.ENVIRONMENT }}
- name: Run unit tests
if: ${{ success() }}
run: dotnet test src\build.slnf