From 7ec59e503c59a4e17aa8f88e59d99e64b1bd9afb Mon Sep 17 00:00:00 2001 From: Gary Hsu Date: Wed, 18 Jan 2023 16:33:05 -0800 Subject: [PATCH 1/4] CI win32 fixes --- .github/jobs/win32.yml | 52 ++++++++++++++++++++++-------------------- 1 file changed, 27 insertions(+), 25 deletions(-) diff --git a/.github/jobs/win32.yml b/.github/jobs/win32.yml index 8445f0b3..7a1d21c3 100644 --- a/.github/jobs/win32.yml +++ b/.github/jobs/win32.yml @@ -7,32 +7,34 @@ parameters: type: string jobs: - - job: ${{parameters.name}} - timeoutInMinutes: 5 - pool: - vmImage: ${{parameters.vmImage}} - variables: - solutionName: 'Win32_${{parameters.platform}}' - buildDir: 'Build/${{variables.solutionName}}' +- job: ${{parameters.name}} + timeoutInMinutes: 5 - steps: - - task: Npm@1 - inputs: - command: 'install' - workingDir: 'Test' - displayName: 'Install Babylon.js NPM packages' + pool: + vmImage: ${{parameters.vmImage}} - - script: | - cmake -B ${{variables.buildDir}} -A ${{parameters.platform}} .. - displayName: 'Generate ${{variables.solutionName}} solution' + variables: + solutionName: 'Win32_${{parameters.platform}}' + buildDir: 'Build/${{variables.solutionName}}' - - task: MSBuild@1 - inputs: - solution: '${{variables.buildDir}}/JsRuntimeHost.sln' - maximumCpuCount: true - configuration: 'RelWithDebInfo' - displayName: 'Build ${{variables.solutionName}}' + steps: + - task: Npm@1 + inputs: + command: 'install' + workingDir: 'Test' + displayName: 'Install Babylon.js NPM packages' - - script: UnitTests - workingDirectory: `${{variables.buildDir}}/Tests/UnitTests/RelWithDebInfo` - displayName: 'Unit Tests' + - script: | + cmake -B ${{variables.buildDir}} -A ${{parameters.platform}} .. + displayName: 'Generate ${{variables.solutionName}} solution' + + - task: MSBuild@1 + inputs: + solution: '${{variables.buildDir}}/JsRuntimeHost.sln' + maximumCpuCount: true + configuration: 'RelWithDebInfo' + displayName: 'Build ${{variables.solutionName}}' + + - script: UnitTests.exe + workingDirectory: '${{variables.buildDir}}/Tests/UnitTests/RelWithDebInfo' + displayName: 'Unit Tests' From 01bd891487b04d2c548076c49d7926d45bbbb02b Mon Sep 17 00:00:00 2001 From: Gary Hsu Date: Wed, 18 Jan 2023 16:40:01 -0800 Subject: [PATCH 2/4] Fix npm install step --- .github/jobs/win32.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/jobs/win32.yml b/.github/jobs/win32.yml index 7a1d21c3..009d7dc0 100644 --- a/.github/jobs/win32.yml +++ b/.github/jobs/win32.yml @@ -21,8 +21,8 @@ jobs: - task: Npm@1 inputs: command: 'install' - workingDir: 'Test' - displayName: 'Install Babylon.js NPM packages' + workingDir: 'Tests' + displayName: 'Install NPM packages' - script: | cmake -B ${{variables.buildDir}} -A ${{parameters.platform}} .. From cbfc58c38ca99855b080ff419f72688e8e304ff0 Mon Sep 17 00:00:00 2001 From: Gary Hsu Date: Wed, 18 Jan 2023 16:43:13 -0800 Subject: [PATCH 3/4] Fix cmake step --- .github/jobs/win32.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/jobs/win32.yml b/.github/jobs/win32.yml index 009d7dc0..8796dcdd 100644 --- a/.github/jobs/win32.yml +++ b/.github/jobs/win32.yml @@ -24,8 +24,7 @@ jobs: workingDir: 'Tests' displayName: 'Install NPM packages' - - script: | - cmake -B ${{variables.buildDir}} -A ${{parameters.platform}} .. + - script: cmake -B ${{variables.buildDir}} -A ${{parameters.platform}} displayName: 'Generate ${{variables.solutionName}} solution' - task: MSBuild@1 From ab9d8ab07f1f7d2dff5c0641ef6fe98cab9b0ef0 Mon Sep 17 00:00:00 2001 From: Gary Hsu Date: Wed, 18 Jan 2023 17:03:33 -0800 Subject: [PATCH 4/4] Move azure-pipelins.yml to .github dir --- azure-pipelines.yml => .github/azure-pipelines.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename azure-pipelines.yml => .github/azure-pipelines.yml (75%) diff --git a/azure-pipelines.yml b/.github/azure-pipelines.yml similarity index 75% rename from azure-pipelines.yml rename to .github/azure-pipelines.yml index c05715d1..f16d1640 100644 --- a/azure-pipelines.yml +++ b/.github/azure-pipelines.yml @@ -6,13 +6,13 @@ pr: jobs: # WIN32 - - template: .github/jobs/win32.yml + - template: jobs/win32.yml parameters: name: Win32_x86 vmImage: 'windows-latest' platform: win32 - - template: .github/jobs/win32.yml + - template: jobs/win32.yml parameters: name: Win32_x64 vmImage: 'windows-latest'