Skip to content

Commit

Permalink
Merge pull request unoplatform#15174 from Youssef1313/refactor-ci
Browse files Browse the repository at this point in the history
ci: Avoid dependency on "UWP convert" for WinUI-only jobs
  • Loading branch information
MartinZikmund authored Jan 23, 2024
2 parents 3e3e87b + b1c9239 commit a99925c
Show file tree
Hide file tree
Showing 6 changed files with 112 additions and 106 deletions.
26 changes: 7 additions & 19 deletions build/ci/.azure-devops-package-netcoremobile.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
parameters:
poolName: ''
UNO_UWP_BUILD: ''
XAML_FLAVOR_BUILD: ''

jobs:
- job: netcoremobile_win_build
Expand All @@ -10,28 +12,11 @@ jobs:

strategy:
matrix:
UWP_NET8:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP
NET8:
UnoDisableNet7Mobile: true
ZipFileTargetFramework: net8

WinUI_NET8:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI
UnoDisableNet7Mobile: true
ZipFileTargetFramework: net8

UWP_NET7:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP
UnoDisableNetCurrentMobile: true
UnoDisableNetCurrent: true
ZipFileTargetFramework: net7

WinUI_NET7:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI
NET7:
UnoDisableNetCurrentMobile: true
UnoDisableNetCurrent: true
ZipFileTargetFramework: net7
Expand All @@ -49,6 +34,9 @@ jobs:
# Use pre-defined local nuget cache for restore
NUGET_PACKAGES: 'C:\NugetPackages'

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- checkout: self
clean: true
Expand Down
15 changes: 5 additions & 10 deletions build/ci/.azure-devops-package-reference.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,22 @@
parameters:
poolName: ''
UNO_UWP_BUILD: ''
XAML_FLAVOR_BUILD: ''

jobs:
- job: reference_package_build
displayName: 'Reference Package Binaries'

pool: ${{ parameters.poolName }}

strategy:
matrix:
UWP:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP

WinUI:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI

variables:
CombinedConfiguration: Release|Any CPU
CI_Build: true
NUGET_PACKAGES: $(build.sourcesdirectory)/.nuget

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- checkout: self
clean: true
Expand Down
15 changes: 5 additions & 10 deletions build/ci/.azure-devops-package-skia.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
parameters:
poolName: ''
UNO_UWP_BUILD: ''
XAML_FLAVOR_BUILD: ''

jobs:
- job: skia_package_build
Expand All @@ -8,16 +10,6 @@ jobs:

pool: ${{ parameters.poolName }}

strategy:
matrix:
UWP:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP

WinUI:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI

variables:
CombinedConfiguration: Release|Any CPU
CI_Build: true
Expand All @@ -27,6 +19,9 @@ jobs:
# We're building packages on linux, so we need to enable WPF support
EnableWindowsTargeting: true

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- checkout: self
clean: true
Expand Down
15 changes: 5 additions & 10 deletions build/ci/.azure-devops-package-wasm.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,14 @@
parameters:
poolName: ''
UNO_UWP_BUILD: ''
XAML_FLAVOR_BUILD: ''

jobs:
- job: wasm_package_build
displayName: 'WebAssembly Package Binaries'

pool: ${{ parameters.poolName }}

strategy:
matrix:
UWP:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP

WinUI:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI

variables:
CombinedConfiguration: Release|Any CPU
CI_Build: true
Expand All @@ -26,6 +18,9 @@ jobs:
# Disabled until the wasm bootstrap can be updated to .NET 8 Pre 3 or later
UnoDisableNetCurrentMobile: true

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- checkout: self
clean: true
Expand Down
73 changes: 25 additions & 48 deletions build/ci/.azure-devops-skia-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ parameters:
vmImage: ''
vmMacImage: ''
poolName: ''
UNO_UWP_BUILD: ''
XAML_FLAVOR_BUILD: ''

snapshotGroups:
- 0
Expand Down Expand Up @@ -29,15 +31,8 @@ jobs:
UnoDisableNetCurrentMobile: true
UnoDisableNetCurrent: true

strategy:
matrix:
UWP:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP

WinUI:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI
UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- checkout: self
Expand Down Expand Up @@ -116,11 +111,14 @@ jobs:
vmImage: ${{ parameters.vmImage }}

dependsOn: Skia_Tests_Build
condition: and(succeeded(), eq(variables['UNO_UWP_BUILD'], 'false'))

variables:
SamplesAppArtifactName: skia-gtk-samples-app-WinUI
SamplesAppArtifactPath: $(build.sourcesdirectory)/build/$(SamplesAppArtifactName)
SnapshotGroupCount: ${{ parameters.snapshotGroupCount }}
UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

strategy:
matrix:
Expand Down Expand Up @@ -160,39 +158,15 @@ jobs:

strategy:
matrix:
UWP_GROUP_0:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP
GROUP_0:
UITEST_RUNTIME_TEST_GROUP: 0
UITEST_RUNTIME_TEST_GROUP_COUNT: 3

UWP_GROUP_1:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP
GROUP_1:
UITEST_RUNTIME_TEST_GROUP: 1
UITEST_RUNTIME_TEST_GROUP_COUNT: 3

UWP_GROUP_2:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP
UITEST_RUNTIME_TEST_GROUP: 2
UITEST_RUNTIME_TEST_GROUP_COUNT: 3

WinUI_GROUP_0:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI
UITEST_RUNTIME_TEST_GROUP: 0
UITEST_RUNTIME_TEST_GROUP_COUNT: 3

WinUI_GROUP_1:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI
UITEST_RUNTIME_TEST_GROUP: 1
UITEST_RUNTIME_TEST_GROUP_COUNT: 3

WinUI_GROUP_2:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI
GROUP_2:
UITEST_RUNTIME_TEST_GROUP: 2
UITEST_RUNTIME_TEST_GROUP_COUNT: 3

Expand All @@ -209,6 +183,9 @@ jobs:
UnoDisableNetCurrentMobile: true
UnoDisableNetCurrent: true

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:

- template: templates/download-winui-converted-tree.yml
Expand Down Expand Up @@ -262,11 +239,15 @@ jobs:
vmImage: ${{ parameters.vmImage }}

dependsOn: Skia_Tests_Build
condition: and(succeeded(), eq(variables['UNO_UWP_BUILD'], 'false'))

variables:
SamplesAppArtifactName: skia-wpf-samples-app-WinUI
SamplesAppArtifactPath: $(build.sourcesdirectory)/build/$(SamplesAppArtifactName)

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- task: DownloadBuildArtifacts@0
inputs:
Expand Down Expand Up @@ -296,22 +277,15 @@ jobs:
pool:
vmImage: ${{ parameters.vmImage }}

strategy:
matrix:
UWP:
UNO_UWP_BUILD: true
XAML_FLAVOR_BUILD: UWP

WinUI:
UNO_UWP_BUILD: false
XAML_FLAVOR_BUILD: WinUI

dependsOn: Skia_Tests_Build

variables:
SamplesAppArtifactName: skia-wpf-samples-app-$(XAML_FLAVOR_BUILD)
SamplesAppArtifactPath: $(build.sourcesdirectory)/build/$(SamplesAppArtifactName)

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- task: DownloadBuildArtifacts@0
inputs:
Expand All @@ -337,16 +311,19 @@ jobs:
- job: Uno_Islands_Skia_Wpf_Runtime_Tests_Build
displayName: 'Run Uno Islands Skia WPF Runtime Tests'
timeoutInMinutes: 45

condition: and(succeeded(), eq(variables['UNO_UWP_BUILD'], 'false'))
pool:
vmImage: ${{ parameters.vmImage }}

dependsOn: Skia_Tests_Build

variables:
SamplesAppArtifactName: uno-islands-skia-wpf-samples-app-UWP
SamplesAppArtifactName: uno-islands-skia-wpf-samples-app-WinUI
SamplesAppArtifactPath: $(build.sourcesdirectory)/build/$(SamplesAppArtifactName)

UNO_UWP_BUILD: ${{ parameters.UNO_UWP_BUILD }}
XAML_FLAVOR_BUILD: ${{ parameters.XAML_FLAVOR_BUILD }}

steps:
- task: DownloadBuildArtifacts@0
inputs:
Expand Down
Loading

0 comments on commit a99925c

Please sign in to comment.