diff options
author | Kyle Edwards <kyle.edwards@kitware.com> | 2020-10-16 20:19:11 (GMT) |
---|---|---|
committer | Kyle Edwards <kyle.edwards@kitware.com> | 2020-10-22 15:24:39 (GMT) |
commit | 64afabdbcb265acb53a9b8f8cb86465d31f2ca61 (patch) | |
tree | ca2616a38a2bf7c80d8635d7fd0f2957645a0a45 /Tests/CMakeGUI | |
parent | 609122007dc074739b394d2f70f674bbccca6073 (diff) | |
download | CMake-64afabdbcb265acb53a9b8f8cb86465d31f2ca61.zip CMake-64afabdbcb265acb53a9b8f8cb86465d31f2ca61.tar.gz CMake-64afabdbcb265acb53a9b8f8cb86465d31f2ca61.tar.bz2 |
CMakePresets.json: Split cmakeGeneratorConfig field
Make this field separate for both architecture and toolset. Allow
architecture and toolset to be either strings or objects with value
and strategy fields.
Fixes: #21317
Diffstat (limited to 'Tests/CMakeGUI')
-rw-r--r-- | Tests/CMakeGUI/QCMakePresetComboBoxTest.cxx | 6 | ||||
-rw-r--r-- | Tests/CMakeGUI/QCMakePresetItemModelTest.cxx | 12 | ||||
-rw-r--r-- | Tests/CMakeGUI/QCMakePresetTest.cxx | 11 |
3 files changed, 19 insertions, 10 deletions
diff --git a/Tests/CMakeGUI/QCMakePresetComboBoxTest.cxx b/Tests/CMakeGUI/QCMakePresetComboBoxTest.cxx index 6ee55c3..a95d008 100644 --- a/Tests/CMakeGUI/QCMakePresetComboBoxTest.cxx +++ b/Tests/CMakeGUI/QCMakePresetComboBoxTest.cxx @@ -24,8 +24,9 @@ void QCMakePresetComboBoxTest::changePresets() /*description=*/"", /*generator=*/"Ninja", /*architecture=*/"", + /*setArchitecture=*/true, /*toolset=*/"", - /*setGenConfig=*/true, + /*setToolset=*/true, /*enabled=*/true, }, }); @@ -48,8 +49,9 @@ void QCMakePresetComboBoxTest::changePresets() /*description=*/"", /*generator=*/"Ninja Multi-Config", /*architecture=*/"", + /*setArchitecture=*/true, /*toolset=*/"", - /*setGenConfig=*/true, + /*setToolset=*/true, /*enabled=*/true, }, }); diff --git a/Tests/CMakeGUI/QCMakePresetItemModelTest.cxx b/Tests/CMakeGUI/QCMakePresetItemModelTest.cxx index ee45d39..97dbb30 100644 --- a/Tests/CMakeGUI/QCMakePresetItemModelTest.cxx +++ b/Tests/CMakeGUI/QCMakePresetItemModelTest.cxx @@ -32,8 +32,9 @@ void QCMakePresetItemModelTest::initTestCase_data() /*description=*/"", /*generator=*/"", /*architecture=*/"", + /*setArchitecture=*/true, /*toolset=*/"", - /*setGenConfig=*/true, + /*setToolset=*/true, /*enabled=*/true, }, QCMakePreset{ @@ -42,8 +43,9 @@ void QCMakePresetItemModelTest::initTestCase_data() /*description=*/"", /*generator=*/"", /*architecture=*/"", + /*setArchitecture=*/true, /*toolset=*/"", - /*setGenConfig=*/true, + /*setToolset=*/true, /*enabled=*/true, }, QCMakePreset{ @@ -52,8 +54,9 @@ void QCMakePresetItemModelTest::initTestCase_data() /*description=*/"Long Description", /*generator=*/"", /*architecture=*/"", + /*setArchitecture=*/true, /*toolset=*/"", - /*setGenConfig=*/true, + /*setToolset=*/true, /*enabled=*/true, }, QCMakePreset{ @@ -62,8 +65,9 @@ void QCMakePresetItemModelTest::initTestCase_data() /*description=*/"", /*generator=*/"", /*architecture=*/"", + /*setArchitecture=*/true, /*toolset=*/"", - /*setGenConfig=*/true, + /*setToolset=*/true, /*enabled=*/false, }, }; diff --git a/Tests/CMakeGUI/QCMakePresetTest.cxx b/Tests/CMakeGUI/QCMakePresetTest.cxx index 8fd07e7..2081055 100644 --- a/Tests/CMakeGUI/QCMakePresetTest.cxx +++ b/Tests/CMakeGUI/QCMakePresetTest.cxx @@ -16,8 +16,9 @@ QCMakePreset makePreset() /*description=*/"description", /*generator=*/"generator", /*architecture=*/"architecture", + /*setArchitecture=*/true, /*toolset=*/"toolset", - /*setGenConfig=*/true, + /*setToolset=*/true, /*enabled=*/true, }; } @@ -69,12 +70,14 @@ void QCMakePresetTest::equality_data() QTest::newRow("architecture") << makePreset(&QCMakePreset::architecture, "other-architecture") << false << true << false; + QTest::newRow("setArchitecture") + << makePreset(&QCMakePreset::setArchitecture, false) << false << false + << true; QTest::newRow("toolset") << makePreset(&QCMakePreset::toolset, "other-toolset") << false << false << true; - QTest::newRow("setGenConfig") - << makePreset(&QCMakePreset::setGenConfig, false) << false << false - << true; + QTest::newRow("setToolset") + << makePreset(&QCMakePreset::setToolset, false) << false << false << true; QTest::newRow("enabled") << makePreset(&QCMakePreset::enabled, false) << false << false << true; } |