aboutsummaryrefslogtreecommitdiff
path: root/src/qt/test
diff options
context:
space:
mode:
authorTheCharlatan <seb.kung@gmail.com>2023-05-24 16:18:59 +0200
committerTheCharlatan <seb.kung@gmail.com>2023-05-30 17:26:51 +0200
commitdb77f87c6365cb5f414036d6bfb1a12705772028 (patch)
tree30e4524849540d22fb8228c5bc87e75ebed1d647 /src/qt/test
parentc27e4bdc35bc7cedd1ee07e98a52c230241120d1 (diff)
scripted-diff: move settings to common namespace
-BEGIN VERIFY SCRIPT- sed -i 's/namespace\ util/namespace\ common/g' src/common/settings.cpp src/common/settings.h sed -i 's/util\:\:GetSetting/common\:\:GetSetting/g' $( git grep -l 'util\:\:GetSetting') sed -i 's/util\:\:Setting/common\:\:Setting/g' $( git grep -l 'util\:\:Setting') sed -i 's/util\:\:FindKey/common\:\:FindKey/g' $( git grep -l 'util\:\:FindKey') sed -i 's/util\:\:ReadSettings/common\:\:ReadSettings/g' $( git grep -l 'util\:\:ReadSettings') sed -i 's/util\:\:WriteSettings/common\:\:WriteSettings/g' $( git grep -l 'util\:\:WriteSettings') -END VERIFY SCRIPT-
Diffstat (limited to 'src/qt/test')
-rw-r--r--src/qt/test/optiontests.cpp10
-rw-r--r--src/qt/test/optiontests.h2
2 files changed, 6 insertions, 6 deletions
diff --git a/src/qt/test/optiontests.cpp b/src/qt/test/optiontests.cpp
index 0838e21678..e5a5179d87 100644
--- a/src/qt/test/optiontests.cpp
+++ b/src/qt/test/optiontests.cpp
@@ -18,13 +18,13 @@
OptionTests::OptionTests(interfaces::Node& node) : m_node(node)
{
- gArgs.LockSettings([&](util::Settings& s) { m_previous_settings = s; });
+ gArgs.LockSettings([&](common::Settings& s) { m_previous_settings = s; });
}
void OptionTests::init()
{
// reset args
- gArgs.LockSettings([&](util::Settings& s) { s = m_previous_settings; });
+ gArgs.LockSettings([&](common::Settings& s) { s = m_previous_settings; });
gArgs.ClearPathCache();
}
@@ -76,14 +76,14 @@ void OptionTests::integerGetArgBug()
// Test regression https://github.com/bitcoin/bitcoin/issues/24457. Ensure
// that setting integer prune value doesn't cause an exception to be thrown
// in the OptionsModel constructor
- gArgs.LockSettings([&](util::Settings& settings) {
+ gArgs.LockSettings([&](common::Settings& settings) {
settings.forced_settings.erase("prune");
settings.rw_settings["prune"] = 3814;
});
gArgs.WriteSettingsFile();
bilingual_str error;
QVERIFY(OptionsModel{m_node}.Init(error));
- gArgs.LockSettings([&](util::Settings& settings) {
+ gArgs.LockSettings([&](common::Settings& settings) {
settings.rw_settings.erase("prune");
});
gArgs.WriteSettingsFile();
@@ -95,7 +95,7 @@ void OptionTests::parametersInteraction()
// It was fixed via https://github.com/bitcoin-core/gui/pull/568.
// With fListen=false in ~/.config/Bitcoin/Bitcoin-Qt.conf and all else left as default,
// bitcoin-qt should set both -listen and -listenonion to false and start successfully.
- gArgs.LockSettings([&](util::Settings& s) {
+ gArgs.LockSettings([&](common::Settings& s) {
s.forced_settings.erase("listen");
s.forced_settings.erase("listenonion");
});
diff --git a/src/qt/test/optiontests.h b/src/qt/test/optiontests.h
index f8c0f75c34..2d7b94933f 100644
--- a/src/qt/test/optiontests.h
+++ b/src/qt/test/optiontests.h
@@ -26,7 +26,7 @@ private Q_SLOTS:
private:
interfaces::Node& m_node;
- util::Settings m_previous_settings;
+ common::Settings m_previous_settings;
};
#endif // BITCOIN_QT_TEST_OPTIONTESTS_H