Skip to content

Commit a26bd31

Browse files
committed
Run the tests without vcpkg
1 parent 557306e commit a26bd31

File tree

2 files changed

+18
-29
lines changed

2 files changed

+18
-29
lines changed

azure-devops/run-build.yml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -53,20 +53,16 @@ jobs:
5353
useVcpkgToolchainFile: true
5454
cmakeAppendedArgs: |
5555
-G Ninja -DBUILD_TESTING=TRUE -DENABLE_XUNIT_OUTPUT=TRUE -DADDITIONAL_LIT_FLAGS=-j$(testParallelism)
56-
- task: PowerShell@2
56+
- task: CmdLine@2
5757
displayName: 'Run Tests'
5858
timeoutInMinutes: 120
5959
condition: in('${{ parameters.targetPlatform }}', 'x64', 'x86')
6060
inputs:
6161
workingDirectory: $(Build.ArtifactStagingDirectory)/${{ parameters.targetPlatform }}
62-
targetType: inline
6362
script: |
64-
Add-Content -Path ./run-tests.cmd -Value "set PATH=$(split-path (get-command ctest).source);%PATH%"
65-
Add-Content -Path ./run-tests.cmd -Value "set PATH=$(split-path (get-command clang-cl).source);%PATH%"
66-
$currentDir = "$((Get-Item -Path "./").FullName)"
67-
Add-Content -Path ./run-tests.cmd -Value "cd $currentDir"
68-
Add-Content -Path ./run-tests.cmd -Value "ctest -V"
69-
$(vcpkgLocation)/vcpkg.exe env --triplet ${{ parameters.targetPlatform }}-windows "$currentDir/run-tests.cmd"
63+
call "%PROGRAMFILES(X86)%\Microsoft Visual Studio\2019\Preview\Common7\Tools\VsDevCmd.bat" ^
64+
-arch=${{ parameters.vsDevCmdArch }} -host_arch=${{ parameters.vsDevCmdArch }} -no_logo
65+
ctest -V
7066
- task: PublishTestResults@2
7167
displayName: 'Publish libcxx Tests'
7268
timeoutInMinutes: 10

azure-pipelines.yml

Lines changed: 14 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -5,40 +5,29 @@
55

66
variables:
77
agentPool: 'StlBuild-2020-03-28'
8-
vcpkgLocation: '$(Build.SourcesDirectory)/vcpkg'
98

109
stages:
1110
- stage: Code_Format_Validation
12-
displayName: "Code Format Validation"
11+
displayName: 'Code Format Validation'
1312
jobs:
1413
- job: Run_Code_Format_Validation
1514
timeoutInMinutes: 90
16-
displayName: "Run Validation"
15+
displayName: 'Run Validation'
1716
pool:
1817
name: $(agentPool)
1918

2019
steps:
2120
- checkout: self
2221
clean: true
2322
submodules: true
24-
# TRANSITION: Once issue #19 or #33 is resolved on https://github.com/lukka/CppBuildTasks we can drop
25-
# building boost-build here.
26-
- task: run-vcpkg@0
27-
displayName: 'Setup environment variables for run-cmake'
28-
timeoutInMinutes: 10
29-
inputs:
30-
setupOnly: true
31-
vcpkgArguments: 'boost-build'
32-
vcpkgDirectory: '$(vcpkgLocation)'
33-
vcpkgTriplet: 'x64-windows'
34-
- task: run-cmake@0
23+
- script: |
24+
call "%PROGRAMFILES(X86)%\Microsoft Visual Studio\2019\Preview\Common7\Tools\VsDevCmd.bat" ^
25+
-arch=amd64 -host_arch=amd64 -no_logo
26+
cmake -G Ninja -DCMAKE_CXX_COMPILER=cl -DCMAKE_BUILD_TYPE=Release ^
27+
-S $(Build.SourcesDirectory)\tools -B $(Build.ArtifactStagingDirectory)\tools
28+
cd $(Build.ArtifactStagingDirectory)\tools
29+
cmake --build .
3530
displayName: 'Build Support Tools'
36-
timeoutInMinutes: 2
37-
inputs:
38-
cmakeListsTxtPath: 'tools/CMakeSettings.json'
39-
useVcpkgToolchainFile: true
40-
configurationRegexFilter: '.*x64-Release.*'
41-
buildDirectory: $(Build.ArtifactStagingDirectory)/tools
4231
- task: BatchScript@1
4332
displayName: 'Enforce clang-format'
4433
timeoutInMinutes: 60
@@ -54,20 +43,24 @@ stages:
5443
failOnStandardError: true
5544
arguments: '$(Build.ArtifactStagingDirectory)/tools/validate/validate.exe'
5645
- stage: Build_And_Test
57-
displayName: "Build and Test the STL"
46+
displayName: 'Build and Test'
5847
jobs:
5948
- template: azure-devops/run-build.yml
6049
parameters:
6150
targetPlatform: x86
51+
vsDevCmdArch: x86
6252

6353
- template: azure-devops/run-build.yml
6454
parameters:
6555
targetPlatform: x64
56+
vsDevCmdArch: amd64
6657

6758
- template: azure-devops/run-build.yml
6859
parameters:
6960
targetPlatform: arm
61+
vsDevCmdArch: arm
7062

7163
- template: azure-devops/run-build.yml
7264
parameters:
7365
targetPlatform: arm64
66+
vsDevCmdArch: arm64

0 commit comments

Comments
 (0)