From b20d4e68defc77b9d300b3d8bdb16060122e16b4 Mon Sep 17 00:00:00 2001 From: Paul Colby Date: Fri, 10 Jan 2025 08:52:53 +1100 Subject: [PATCH] Dont' expect a warning when expecting errors The error/s will trump (prevent) the warning. --- test/unit/cli/testabstractcommand.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/cli/testabstractcommand.cpp b/test/unit/cli/testabstractcommand.cpp index 5d5716400..145c9f8db 100644 --- a/test/unit/cli/testabstractcommand.cpp +++ b/test/unit/cli/testabstractcommand.cpp @@ -356,7 +356,7 @@ void TestAbstractCommand::processOptions_timeout() MockCommand mock; const int defaultTimeout = mock.discoveryAgent->lowEnergyDiscoveryTimeout(); // eg 20s on Linux. - if (defaultTimeout == -1) { + if ((!expectErrors) && (defaultTimeout == -1)) { QTest::ignoreMessage(QtWarningMsg, "Platform does not support Bluetooth scan timeout"); } const QStringList errors = mock.processOptions(parser);