CMake: Add a RunCMake test for feature resolution
qt_feature() lets DISABLE win over ENABLE, which wins over
AUTODETECT and CONDITION, and forces a feature OFF when EMIT_IF does
not hold. None of that was tested; RunCMake/QtFeatureExclusiveGroup
only covers exclusive groups.
Port the assertions from cmake/tests/features, which has not been
runnable for a long time, including its check that feature values are
visible in subdirectories.
Change-Id: I9a4674b5e544f5e1bb919f6e96dc23a173aab0d6
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
| commit | 6309ce5217d34f6d1163fe334ce61b0f63c9b236 |
| parent | a7281384a8500258cd07d0596cadab85e0c61066 |
| author | Joerg Bornemann <joerg.bornemann@qt.io> |
| committer | Joerg Bornemann <joerg.bornemann@qt.io> |
| commit time | Wed, 21 Oct 2026 15:32:13 +0000 |
- M tests/auto/cmake/RunCMake/CMakeLists.txt
- A tests/auto/cmake/RunCMake/QtFeature/CMakeLists.txt
- A tests/auto/cmake/RunCMake/QtFeature/RunCMakeTest.cmake
- A tests/auto/cmake/RunCMake/QtFeature/check_features.cmake
- A tests/auto/cmake/RunCMake/QtFeature/feature_resolution.cmake
- A tests/auto/cmake/RunCMake/QtFeature/subdir/CMakeLists.txt