Skip to content

Commit ff7f5df

Browse files
authored
1. Fully test unstable ABI (#4635)
2. Selectively exercise cmake `-DPYBIND11_TEST_OVERRIDE`: ubuntu, macos, windows Extra work added to quick jobs, based on timings below, to not increase the GHA start-to-last-job-finished time. ``` Duration ^ Number of pytest runs ^ ^ Job identifier ^ ^ ^ 0:03:48.024227 1 1___3___Clang_3.6___C++11___x64.txt 0:03:58.992814 1 2___3___Clang_3.7___C++11___x64.txt 0:04:25.758942 1 1___3.7___Debian___x86____Install.txt 0:04:50.148276 1 4___3___Clang_7___C++11___x64.txt 0:04:55.784558 1 13___3___Clang_15___C++20___x64.txt 0:04:57.048754 1 6___3___Clang_dev___C++11___x64.txt 0:05:00.485181 1 7___3___Clang_5___C++14___x64.txt 0:05:03.744964 1 2___3___almalinux8___x64.txt 0:05:06.222752 1 5___3___Clang_9___C++11___x64.txt 0:05:11.767022 1 2___3___GCC_7___C++17__x64.txt 0:05:18.634930 1 2___3.11__deadsnakes____x64.txt 0:05:22.810995 1 1___3___GCC_7___C++11__x64.txt 0:05:25.275317 1 12___3___Clang_14___C++20___x64.txt 0:05:32.058174 1 5___3___GCC_10___C++17__x64.txt 0:05:39.381351 1 7___3___GCC_12___C++20__x64.txt 0:05:40.502252 1 8___3___Clang_10___C++17___x64.txt 0:05:59.344905 1 3___3___Clang_3.9___C++11___x64.txt 0:06:10.825147 1 6___3___GCC_11___C++20__x64.txt 0:06:20.655443 1 3___3___almalinux9___x64.txt 0:06:22.472061 1 3___3___GCC_8___C++14__x64.txt 0:06:42.647406 1 11___3___Clang_13___C++20___x64.txt 0:06:53.352720 1 1___3.10___CUDA_11.7___Ubuntu_22.04.txt 0:07:07.357801 1 2___3.7___MSVC_2019___x86_-DCMAKE_CXX_STANDARD=14.txt 0:07:09.057603 1 1___3___centos7___x64.txt 0:07:15.546282 1 1___3.8___MSVC_2019__Debug____x86_-DCMAKE_CXX_STANDARD=17.txt 0:07:22.566022 1 4___3___GCC_8___C++17__x64.txt 0:08:13.592674 1 2___3.9___MSVC_2019__Debug____x86_-DCMAKE_CXX_STANDARD=20.txt 0:08:16.422768 1 9___3___Clang_11___C++20___x64.txt 0:08:21.168457 1 3___3.8___MSVC_2019___x86_-DCMAKE_CXX_STANDARD=17.txt 0:08:27.129468 1 10___3___Clang_12___C++20___x64.txt 0:09:35.045470 1 1___3.10___windows-latest___clang-latest.txt 0:09:57.361843 1 1___3.9___MSVC_2022_C++20___x64.txt 0:10:35.187767 1 1___3.6___MSVC_2019___x86.txt 0:11:14.691200 4 2___3.9___ubuntu-20.04___x64.txt 0:11:37.701167 1 1_macos-latest___brew_install_llvm.txt 0:11:38.688299 4 4___3.11___ubuntu-20.04___x64.txt 0:11:52.720216 1 4___3.9___MSVC_2019___x86_-DCMAKE_CXX_STANDARD=20.txt 0:13:23.456591 4 6___pypy-3.8___ubuntu-20.04___x64_-DPYBIND11_FINDPYTHON=ON.txt 0:13:25.863592 2 1___3___ICC_latest___x64.txt 0:13:32.411758 3 9___3.9___windows-2022___x64.txt 0:13:45.473377 4 3___3.10___ubuntu-20.04___x64.txt 0:13:55.366447 4 5___pypy-3.7___ubuntu-20.04___x64.txt 0:13:57.969502 3 10___3.10___windows-2022___x64.txt 0:14:19.837475 3 11___3.11___windows-2022___x64.txt 0:14:33.316770 4 1___3.6___ubuntu-20.04___x64_-DPYBIND11_FINDPYTHON=ON_-DCMA.txt 0:15:34.449278 4 22___3.6___windows-2019___x64_-DPYBIND11_FINDPYTHON=ON.txt 0:16:25.189055 2 1___3.9-dbg__deadsnakes____Valgrind___x64.txt 0:17:20.956667 4 15___3.6___macos-latest___x64.txt 0:17:27.513891 4 23___3.9___windows-2019___x64.txt 0:17:58.783286 3 8___3.6___windows-2022___x64.txt 0:18:25.917828 4 7___pypy-3.9___ubuntu-20.04___x64.txt 0:19:17.399820 3 13___pypy-3.8___windows-2022___x64.txt 0:19:45.002122 3 12___pypy-3.7___windows-2022___x64.txt 0:20:03.201926 4 16___3.9___macos-latest___x64.txt 0:20:15.415178 4 17___3.10___macos-latest___x64.txt 0:20:20.263216 4 20___pypy-3.8___macos-latest___x64.txt 0:20:31.998226 3 1___3___windows-latest___mingw64.txt 0:20:40.812286 4 18___3.11___macos-latest___x64.txt 0:22:47.714749 4 19___pypy-3.7___macos-latest___x64.txt 0:23:04.435859 3 2___3___windows-latest___mingw32.txt 0:25:48.719597 3 14___pypy-3.9___windows-2022___x64.txt 0:26:01.211688 4 21___pypy-3.9___macos-latest___x64.txt 0:28:19.971015 1 1___3___CentOS7__PGI_22.9___x64.txt ```
1 parent 07725c2 commit ff7f5df

File tree

1 file changed

+51
-1
lines changed

1 file changed

+51
-1
lines changed

.github/workflows/ci.yml

+51-1
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,6 @@ jobs:
164164
-DDOWNLOAD_EIGEN=ON
165165
-DCMAKE_CXX_STANDARD=17
166166
-DPYBIND11_INTERNALS_VERSION=10000000
167-
"-DPYBIND11_TEST_OVERRIDE=test_call_policies.cpp;test_gil_scoped.cpp;test_thread.cpp"
168167
${{ matrix.args }}
169168
170169
- name: Build (unstable ABI)
@@ -497,6 +496,24 @@ jobs:
497496
- name: Interface test
498497
run: cmake --build build --target test_cmake_build
499498

499+
- name: Configure - Exercise cmake -DPYBIND11_TEST_OVERRIDE
500+
if: matrix.gcc == '12'
501+
shell: bash
502+
run: >
503+
cmake -S . -B build_partial
504+
-DPYBIND11_WERROR=ON
505+
-DDOWNLOAD_CATCH=ON
506+
-DCMAKE_CXX_STANDARD=${{ matrix.std }}
507+
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
508+
"-DPYBIND11_TEST_OVERRIDE=test_call_policies.cpp;test_gil_scoped.cpp;test_thread.cpp"
509+
510+
- name: Build - Exercise cmake -DPYBIND11_TEST_OVERRIDE
511+
if: matrix.gcc == '12'
512+
run: cmake --build build_partial -j 2
513+
514+
- name: Python tests - Exercise cmake -DPYBIND11_TEST_OVERRIDE
515+
if: matrix.gcc == '12'
516+
run: cmake --build build_partial --target pytest
500517

501518
# Testing on ICC using the oneAPI apt repo
502519
icc:
@@ -889,6 +906,21 @@ jobs:
889906
- name: Interface test C++20
890907
run: cmake --build build --target test_cmake_build
891908

909+
- name: Configure C++20 - Exercise cmake -DPYBIND11_TEST_OVERRIDE
910+
run: >
911+
cmake -S . -B build_partial
912+
-DPYBIND11_WERROR=ON
913+
-DDOWNLOAD_CATCH=ON
914+
-DDOWNLOAD_EIGEN=ON
915+
-DCMAKE_CXX_STANDARD=20
916+
"-DPYBIND11_TEST_OVERRIDE=test_call_policies.cpp;test_gil_scoped.cpp;test_thread.cpp"
917+
918+
- name: Build C++20 - Exercise cmake -DPYBIND11_TEST_OVERRIDE
919+
run: cmake --build build_partial -j 2
920+
921+
- name: Python tests - Exercise cmake -DPYBIND11_TEST_OVERRIDE
922+
run: cmake --build build_partial --target pytest
923+
892924
mingw:
893925
name: "🐍 3 • windows-latest • ${{ matrix.sys }}"
894926
runs-on: windows-latest
@@ -1105,5 +1137,23 @@ jobs:
11051137
- name: Interface test
11061138
run: cmake --build . --target test_cmake_build -j 2
11071139

1140+
- name: CMake Configure - Exercise cmake -DPYBIND11_TEST_OVERRIDE
1141+
run: >
1142+
cmake -S . -B build_partial
1143+
-DPYBIND11_WERROR=ON
1144+
-DPYBIND11_SIMPLE_GIL_MANAGEMENT=OFF
1145+
-DDOWNLOAD_CATCH=ON
1146+
-DDOWNLOAD_EIGEN=ON
1147+
-DCMAKE_CXX_COMPILER=clang++
1148+
-DCMAKE_CXX_STANDARD=17
1149+
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
1150+
"-DPYBIND11_TEST_OVERRIDE=test_call_policies.cpp;test_gil_scoped.cpp;test_thread.cpp"
1151+
1152+
- name: Build - Exercise cmake -DPYBIND11_TEST_OVERRIDE
1153+
run: cmake --build build_partial -j 2
1154+
1155+
- name: Python tests - Exercise cmake -DPYBIND11_TEST_OVERRIDE
1156+
run: cmake --build build_partial --target pytest -j 2
1157+
11081158
- name: Clean directory
11091159
run: git clean -fdx

0 commit comments

Comments
 (0)