From 020628e3a4e88e36647eaf92bac4b3552796ac6a Mon Sep 17 00:00:00 2001 From: Andrew Chow Date: Wed, 27 Jun 2018 17:05:54 -0700 Subject: Tests for PSBT Added functional tests for PSBT that test the RPCs. Also added all of the BIP 174 test vectors (except for the updater tests) in the functional tests. Added a Unit test for the BIP 174 updater test vector. --- src/Makefile.test.include | 1 + src/wallet/test/psbt_wallet_tests.cpp | 74 +++++++++++++ test/functional/data/rpc_psbt.json | 78 ++++++++++++++ test/functional/rpc_psbt.py | 190 ++++++++++++++++++++++++++++++++++ test/functional/test_runner.py | 1 + 5 files changed, 344 insertions(+) create mode 100644 src/wallet/test/psbt_wallet_tests.cpp create mode 100644 test/functional/data/rpc_psbt.json create mode 100755 test/functional/rpc_psbt.py diff --git a/src/Makefile.test.include b/src/Makefile.test.include index a4d31795ec..b50b75c081 100644 --- a/src/Makefile.test.include +++ b/src/Makefile.test.include @@ -94,6 +94,7 @@ BITCOIN_TESTS =\ if ENABLE_WALLET BITCOIN_TESTS += \ wallet/test/accounting_tests.cpp \ + wallet/test/psbt_wallet_tests.cpp \ wallet/test/wallet_tests.cpp \ wallet/test/wallet_crypto_tests.cpp \ wallet/test/coinselector_tests.cpp diff --git a/src/wallet/test/psbt_wallet_tests.cpp b/src/wallet/test/psbt_wallet_tests.cpp new file mode 100644 index 0000000000..a74ca85349 --- /dev/null +++ b/src/wallet/test/psbt_wallet_tests.cpp @@ -0,0 +1,74 @@ +// Copyright (c) 2017 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