From 3e1b9a4ee2df5ca8ee08b2b805fd0827d1572b3a Mon Sep 17 00:00:00 2001 From: Kolby ML <31669092+KolbyML@users.noreply.github.com> Date: Sat, 18 Feb 2023 21:33:12 -0700 Subject: [PATCH] qt, test: add importpubkey, importprivkey, and importaddress tests --- .../test_bitcoin-qt/test_bitcoin-qt.vcxproj | 3 + src/Makefile.qttest.include | 3 + src/qt/test/importlegacytests.cpp | 223 ++++++++++++++++++ src/qt/test/importlegacytests.h | 27 +++ src/qt/test/test_main.cpp | 4 + 5 files changed, 260 insertions(+) create mode 100644 src/qt/test/importlegacytests.cpp create mode 100644 src/qt/test/importlegacytests.h diff --git a/build_msvc/test_bitcoin-qt/test_bitcoin-qt.vcxproj b/build_msvc/test_bitcoin-qt/test_bitcoin-qt.vcxproj index 16514a0a7c1..a0feeb86f34 100644 --- a/build_msvc/test_bitcoin-qt/test_bitcoin-qt.vcxproj +++ b/build_msvc/test_bitcoin-qt/test_bitcoin-qt.vcxproj @@ -14,6 +14,7 @@ + @@ -25,6 +26,7 @@ + @@ -99,6 +101,7 @@ + diff --git a/src/Makefile.qttest.include b/src/Makefile.qttest.include index 088ef310183..743c8ea2824 100644 --- a/src/Makefile.qttest.include +++ b/src/Makefile.qttest.include @@ -15,6 +15,7 @@ if ENABLE_WALLET TEST_QT_MOC_CPP += \ qt/test/moc_addressbooktests.cpp \ qt/test/moc_importdescriptorstests.cpp \ + qt/test/moc_importlegacytests.cpp \ qt/test/moc_importmultitests.cpp \ qt/test/moc_wallettests.cpp endif # ENABLE_WALLET @@ -23,6 +24,7 @@ TEST_QT_H = \ qt/test/addressbooktests.h \ qt/test/apptests.h \ qt/test/importdescriptorstests.h \ + qt/test/importlegacytests.h \ qt/test/importmultitests.h \ qt/test/optiontests.h \ qt/test/rpcnestedtests.h \ @@ -45,6 +47,7 @@ if ENABLE_WALLET qt_test_test_bitcoin_qt_SOURCES += \ qt/test/addressbooktests.cpp \ qt/test/importdescriptorstests.cpp \ + qt/test/importlegacytests.cpp \ qt/test/importmultitests.cpp \ qt/test/wallettests.cpp \ qt/test/util.cpp \ diff --git a/src/qt/test/importlegacytests.cpp b/src/qt/test/importlegacytests.cpp new file mode 100644 index 00000000000..a20fb004f50 --- /dev/null +++ b/src/qt/test/importlegacytests.cpp @@ -0,0 +1,223 @@ +// Copyright (c) 2023 The Bitcoin Core developers +// Distributed under the MIT software license, see the accompanying +// file COPYING or http://www.opensource.org/licenses/mit-license.php. + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include