aboutsummaryrefslogtreecommitdiff
path: root/src/qt
diff options
context:
space:
mode:
authorHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2024-09-29 14:20:08 +0100
committerHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2024-09-29 14:20:08 +0100
commitcb750b4b405b1036991a49b410a75da95e9d1ac0 (patch)
treea8325561f4a84db63ee272bfb6ff7c9060992170 /src/qt
parentd812cf11896a2214467b6fa72d7b763bac6077c5 (diff)
qt6, test: Use `qWarning()` instead of `QWARN()` macro
The `QWARN()` macro internally uses `QTest::qWarn()`, which has been deprecated since Qt 6.3. Replacing it with `qWarning()` ensures compatibility across all Qt versions.
Diffstat (limited to 'src/qt')
-rw-r--r--src/qt/test/addressbooktests.cpp4
-rw-r--r--src/qt/test/apptests.cpp4
-rw-r--r--src/qt/test/test_main.cpp2
-rw-r--r--src/qt/test/wallettests.cpp4
4 files changed, 7 insertions, 7 deletions
diff --git a/src/qt/test/addressbooktests.cpp b/src/qt/test/addressbooktests.cpp
index f7d66f316e..3d5cb4a863 100644
--- a/src/qt/test/addressbooktests.cpp
+++ b/src/qt/test/addressbooktests.cpp
@@ -222,8 +222,8 @@ void AddressBookTests::addressBookTests()
// framework when it tries to look up unimplemented cocoa functions,
// and fails to handle returned nulls
// (https://bugreports.qt.io/browse/QTBUG-49686).
- QWARN("Skipping AddressBookTests on mac build with 'minimal' platform set due to Qt bugs. To run AppTests, invoke "
- "with 'QT_QPA_PLATFORM=cocoa test_bitcoin-qt' on mac, or else use a linux or windows build.");
+ qWarning() << "Skipping AddressBookTests on mac build with 'minimal' platform set due to Qt bugs. To run AppTests, invoke "
+ "with 'QT_QPA_PLATFORM=cocoa test_bitcoin-qt' on mac, or else use a linux or windows build.";
return;
}
#endif
diff --git a/src/qt/test/apptests.cpp b/src/qt/test/apptests.cpp
index 10abcb00eb..73e04b55c8 100644
--- a/src/qt/test/apptests.cpp
+++ b/src/qt/test/apptests.cpp
@@ -60,8 +60,8 @@ void AppTests::appTests()
// framework when it tries to look up unimplemented cocoa functions,
// and fails to handle returned nulls
// (https://bugreports.qt.io/browse/QTBUG-49686).
- QWARN("Skipping AppTests on mac build with 'minimal' platform set due to Qt bugs. To run AppTests, invoke "
- "with 'QT_QPA_PLATFORM=cocoa test_bitcoin-qt' on mac, or else use a linux or windows build.");
+ qWarning() << "Skipping AppTests on mac build with 'minimal' platform set due to Qt bugs. To run AppTests, invoke "
+ "with 'QT_QPA_PLATFORM=cocoa test_bitcoin-qt' on mac, or else use a linux or windows build.";
return;
}
#endif
diff --git a/src/qt/test/test_main.cpp b/src/qt/test/test_main.cpp
index 958cc7ae88..5116fbacb9 100644
--- a/src/qt/test/test_main.cpp
+++ b/src/qt/test/test_main.cpp
@@ -58,7 +58,7 @@ int main(int argc, char* argv[])
gArgs.ForceSetArg("-natpmp", "0");
std::string error;
- if (!gArgs.ReadConfigFiles(error, true)) QWARN(error.c_str());
+ if (!gArgs.ReadConfigFiles(error, true)) qWarning() << error.c_str();
// Prefer the "minimal" platform for the test instead of the normal default
// platform ("xcb", "windows", or "cocoa") so tests can't unintentionally
diff --git a/src/qt/test/wallettests.cpp b/src/qt/test/wallettests.cpp
index 6a573d284c..98dfe12f08 100644
--- a/src/qt/test/wallettests.cpp
+++ b/src/qt/test/wallettests.cpp
@@ -475,8 +475,8 @@ void WalletTests::walletTests()
// framework when it tries to look up unimplemented cocoa functions,
// and fails to handle returned nulls
// (https://bugreports.qt.io/browse/QTBUG-49686).
- QWARN("Skipping WalletTests on mac build with 'minimal' platform set due to Qt bugs. To run AppTests, invoke "
- "with 'QT_QPA_PLATFORM=cocoa test_bitcoin-qt' on mac, or else use a linux or windows build.");
+ qWarning() << "Skipping WalletTests on mac build with 'minimal' platform set due to Qt bugs. To run AppTests, invoke "
+ "with 'QT_QPA_PLATFORM=cocoa test_bitcoin-qt' on mac, or else use a linux or windows build.";
return;
}
#endif