Skip to content

Commit ed068f0

Browse files
committed
Split CMake build and test
Use the pattern in Windows CI to create two separate steps for build and test. For #6547
1 parent 40e96aa commit ed068f0

File tree

1 file changed

+14
-10
lines changed

1 file changed

+14
-10
lines changed

azure-pipelines.yml

+14-10
Original file line numberDiff line numberDiff line change
@@ -12,37 +12,37 @@ jobs:
1212
image_name: 'ubuntu-latest'
1313
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
1414
build_type: 'Debug'
15-
test_target: 'check'
15+
do_test: true
1616
libtype_flag: ''
1717
Linux.ReleaseWithDebug:
1818
image_name: 'ubuntu-latest'
1919
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
2020
build_type: 'RelWithDebInfo'
21-
test_target: 'check'
21+
do_test: true
2222
libtype_flag: ''
2323
Linux.Release:
2424
image_name: 'ubuntu-latest'
2525
deps: 'sudo apt-get install -y ninja-build clang libicu-dev'
2626
build_type: 'Release'
27-
test_target: 'all'
27+
do_test: false
2828
libtype_flag: ''
2929
OSX.Debug:
3030
image_name: 'macOS-latest'
3131
deps: 'brew install ninja icu4c'
3232
build_type: 'Debug'
33-
test_target: 'check'
33+
do_test: true
3434
libtype_flag: '-DSTATIC_LIBRARY=ON'
3535
OSX.ReleaseWithDebug:
3636
image_name: 'macOS-latest'
3737
deps: 'brew install ninja icu4c'
3838
build_type: 'RelWithDebInfo'
39-
test_target: 'check'
39+
do_test: true
4040
libtype_flag: ''
4141
OSX.Release:
4242
image_name: 'macOS-latest'
4343
deps: 'brew install ninja icu4c'
4444
build_type: 'Release'
45-
test_target: 'all'
45+
do_test: false
4646
libtype_flag: ''
4747

4848
pool:
@@ -66,10 +66,14 @@ jobs:
6666
6767
- script: |
6868
cd build
69-
ninja $TARGET
70-
displayName: 'Build and test'
71-
env:
72-
TARGET: $(test_target)
69+
ninja
70+
displayName: 'Build'
71+
72+
- script: |
73+
cd build
74+
ninja check
75+
displayName: 'Test'
76+
condition: eq(variables['do_test'], true)
7377
7478
- job: MSVC
7579
timeoutInMinutes: 120

0 commit comments

Comments
 (0)