diff options
author | Christian Kandeler <christian.kandeler@digia.com> | 2014-10-06 19:18:16 +0200 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@digia.com> | 2014-10-07 12:07:15 +0200 |
commit | b7e42fbe02d6105c5e449e90f74ef16f30500440 (patch) | |
tree | bf1cfd520371fef4582044ddab3af84ff9dedd11 /tests/auto/blackbox/tst_blackbox.cpp | |
parent | 2202f8b65c6eb3c1fc4784bdc76f758578856432 (diff) |
Make Qt build variants logic more sensible.v1.3.2
We no longer force the Qt build variant to match the build variant
of the application linking against it (except for MSVC, where that
is required).
Change-Id: Ie2c80fbb0d688cdcbab57ad638aaccbbd6988a22
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Diffstat (limited to 'tests/auto/blackbox/tst_blackbox.cpp')
-rw-r--r-- | tests/auto/blackbox/tst_blackbox.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/auto/blackbox/tst_blackbox.cpp b/tests/auto/blackbox/tst_blackbox.cpp index d8a4f0e73..cde04882e 100644 --- a/tests/auto/blackbox/tst_blackbox.cpp +++ b/tests/auto/blackbox/tst_blackbox.cpp @@ -1826,6 +1826,26 @@ void TestBlackbox::inheritQbsSearchPaths() QCOMPARE(runQbs(), 0); } +void TestBlackbox::mixedBuildVariants() +{ + QDir::setCurrent(testDataDir + "/mixed-build-variants"); + Settings settings((QString())); + Profile profile(buildProfileName, &settings); + if (profile.value("qbs.toolchain").toStringList().contains("msvc")) { + QbsRunParameters params; + params.expectFailure = true; + QVERIFY(runQbs(params) != 0); + QVERIFY2(m_qbsStderr.contains("not allowed"), m_qbsStderr.constData()); + } else if (!profile.value("Qt.core.availableBuildVariants").toStringList().contains("release")) { + QbsRunParameters params; + params.expectFailure = true; + QVERIFY(runQbs(params) != 0); + QVERIFY2(m_qbsStderr.contains("not supported"), m_qbsStderr.constData()); + } else { + QCOMPARE(runQbs(), 0); + } +} + void TestBlackbox::mocCppIncluded() { QDir::setCurrent(testDataDir + "/moc_hpp_included"); |