diff options
Diffstat (limited to 'tests/auto/blackbox/tst_blackbox.cpp')
-rw-r--r-- | tests/auto/blackbox/tst_blackbox.cpp | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/tests/auto/blackbox/tst_blackbox.cpp b/tests/auto/blackbox/tst_blackbox.cpp index f65d462d2..72f610364 100644 --- a/tests/auto/blackbox/tst_blackbox.cpp +++ b/tests/auto/blackbox/tst_blackbox.cpp @@ -5621,8 +5621,8 @@ void TestBlackbox::qbsSession() } else if (msgType == "task-progress") { receivedProgressData = true; } else if (msgType == "command-description") { - if (receivedMessage.value("message").toString().contains( - QDir::separator() + QString("main.cpp"))) { + if (QDir::fromNativeSeparators(receivedMessage.value("message").toString()) + .contains("/main.cpp")) { receivedCommandDescription = true; } } else if (msgType == "process-result") { @@ -6615,6 +6615,25 @@ void TestBlackbox::generatedArtifactAsInputToDynamicRule() QVERIFY2(!m_qbsStdout.contains("generating"), m_qbsStdout.constData()); } +void TestBlackbox::generateLinkerMapFile() +{ + QDir::setCurrent(testDataDir + "/generate-linker-map-file"); + QCOMPARE(runQbs(), 0); + const bool isUsed = m_qbsStdout.contains("use test: true"); + const bool isNotUsed = m_qbsStdout.contains("use test: false"); + QVERIFY(isUsed != isNotUsed); + if (isUsed) { + QVERIFY(QFile::exists(relativeProductBuildDir("app-map") + + "/app-map.map")); + QVERIFY(!QFile::exists(relativeProductBuildDir("app-nomap") + + "/app-nomap.map")); + QVERIFY(!QFile::exists(relativeProductBuildDir("app-nomap-default") + + "/app-nomap-default.map")); + } else { + QSKIP("Unsupported toolchain. Skipping."); + } +} + void TestBlackbox::generator() { QFETCH(QString, inputFile); |