diff options
Diffstat (limited to 'src/qt/test')
-rw-r--r-- | src/qt/test/paymentservertests.cpp | 6 | ||||
-rw-r--r-- | src/qt/test/paymentservertests.h | 2 | ||||
-rw-r--r-- | src/qt/test/rpcnestedtests.cpp | 6 | ||||
-rw-r--r-- | src/qt/test/test_main.cpp | 2 |
4 files changed, 8 insertions, 8 deletions
diff --git a/src/qt/test/paymentservertests.cpp b/src/qt/test/paymentservertests.cpp index b9a8ad6e28..c7830071ed 100644 --- a/src/qt/test/paymentservertests.cpp +++ b/src/qt/test/paymentservertests.cpp @@ -25,7 +25,7 @@ X509 *parse_b64der_cert(const char* cert_data) std::vector<unsigned char> data = DecodeBase64(cert_data); assert(data.size() > 0); const unsigned char* dptr = &data[0]; - X509 *cert = d2i_X509(NULL, &dptr, data.size()); + X509 *cert = d2i_X509(nullptr, &dptr, data.size()); assert(cert); return cert; } @@ -66,7 +66,7 @@ void PaymentServerTests::paymentServerTests() { SelectParams(CBaseChainParams::MAIN); OptionsModel optionsModel; - PaymentServer* server = new PaymentServer(NULL, false); + PaymentServer* server = new PaymentServer(nullptr, false); X509_STORE* caStore = X509_STORE_new(); X509_STORE_add_cert(caStore, parse_b64der_cert(caCert1_BASE64)); PaymentServer::LoadRootCAs(caStore); @@ -205,7 +205,7 @@ void PaymentServerTests::paymentServerTests() delete server; } -void RecipientCatcher::getRecipient(SendCoinsRecipient r) +void RecipientCatcher::getRecipient(const SendCoinsRecipient& r) { recipient = r; } diff --git a/src/qt/test/paymentservertests.h b/src/qt/test/paymentservertests.h index 9ffcbb02ac..faf167f2c6 100644 --- a/src/qt/test/paymentservertests.h +++ b/src/qt/test/paymentservertests.h @@ -26,7 +26,7 @@ class RecipientCatcher : public QObject Q_OBJECT public Q_SLOTS: - void getRecipient(SendCoinsRecipient r); + void getRecipient(const SendCoinsRecipient& r); public: SendCoinsRecipient recipient; diff --git a/src/qt/test/rpcnestedtests.cpp b/src/qt/test/rpcnestedtests.cpp index fbad9e544a..cd9ab23457 100644 --- a/src/qt/test/rpcnestedtests.cpp +++ b/src/qt/test/rpcnestedtests.cpp @@ -41,7 +41,7 @@ void RPCNestedTests::rpcNestedTests() std::string path = QDir::tempPath().toStdString() + "/" + strprintf("test_bitcoin_qt_%lu_%i", (unsigned long)GetTime(), (int)(GetRand(100000))); QDir dir(QString::fromStdString(path)); dir.mkpath("."); - ForceSetArg("-datadir", path); + gArgs.ForceSetArg("-datadir", path); //mempool.setSanityCheck(1.0); TestingSetup test; @@ -69,13 +69,13 @@ void RPCNestedTests::rpcNestedTests() RPCConsole::RPCExecuteCommandLine(result, "getblockchaininfo "); //whitespace at the end will be tolerated QVERIFY(result.substr(0,1) == "{"); - (RPCConsole::RPCExecuteCommandLine(result, "getblockchaininfo()[\"chain\"]")); //Quote path identifier are allowed, but look after a child contaning the quotes in the key + (RPCConsole::RPCExecuteCommandLine(result, "getblockchaininfo()[\"chain\"]")); //Quote path identifier are allowed, but look after a child containing the quotes in the key QVERIFY(result == "null"); (RPCConsole::RPCExecuteCommandLine(result, "createrawtransaction [] {} 0")); //parameter not in brackets are allowed (RPCConsole::RPCExecuteCommandLine(result2, "createrawtransaction([],{},0)")); //parameter in brackets are allowed QVERIFY(result == result2); - (RPCConsole::RPCExecuteCommandLine(result2, "createrawtransaction( [], {} , 0 )")); //whitespace between parametres is allowed + (RPCConsole::RPCExecuteCommandLine(result2, "createrawtransaction( [], {} , 0 )")); //whitespace between parameters is allowed QVERIFY(result == result2); RPCConsole::RPCExecuteCommandLine(result, "getblock(getbestblockhash())[tx][0]", &filtered); diff --git a/src/qt/test/test_main.cpp b/src/qt/test/test_main.cpp index 1b28a285f1..80a00a634a 100644 --- a/src/qt/test/test_main.cpp +++ b/src/qt/test/test_main.cpp @@ -57,7 +57,7 @@ int main(int argc, char *argv[]) bool fInvalid = false; // Prefer the "minimal" platform for the test instead of the normal default - // platform ("xcb", "windows", or "cocoa") so tests can't unintentially + // platform ("xcb", "windows", or "cocoa") so tests can't unintentionally // interfere with any background GUIs and don't require extra resources. #if defined(WIN32) _putenv_s("QT_QPA_PLATFORM", "minimal"); |