mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-10 03:47:29 -03:00
Compare commits
2 commits
1ec3e30278
...
6fda619f56
Author | SHA1 | Date | |
---|---|---|---|
|
6fda619f56 | ||
|
fa8e0956c2 |
2 changed files with 3 additions and 4 deletions
|
@ -1,4 +1,4 @@
|
||||||
// Copyright (c) 2011-2022 The Bitcoin Core developers
|
// Copyright (c) 2011-present The Bitcoin Core developers
|
||||||
// Distributed under the MIT software license, see the accompanying
|
// Distributed under the MIT software license, see the accompanying
|
||||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||||
|
|
||||||
|
@ -443,7 +443,7 @@ RPCHelpMan listtransactions()
|
||||||
"\nIf a label name is provided, this will return only incoming transactions paying to addresses with the specified label.\n"
|
"\nIf a label name is provided, this will return only incoming transactions paying to addresses with the specified label.\n"
|
||||||
"\nReturns up to 'count' most recent transactions skipping the first 'from' transactions.\n",
|
"\nReturns up to 'count' most recent transactions skipping the first 'from' transactions.\n",
|
||||||
{
|
{
|
||||||
{"label|dummy", RPCArg::Type::STR, RPCArg::Optional::OMITTED, "If set, should be a valid label name to return only incoming transactions\n"
|
{"label", RPCArg::Type::STR, RPCArg::Optional::OMITTED, "If set, should be a valid label name to return only incoming transactions\n"
|
||||||
"with the specified label, or \"*\" to disable filtering and return all transactions."},
|
"with the specified label, or \"*\" to disable filtering and return all transactions."},
|
||||||
{"count", RPCArg::Type::NUM, RPCArg::Default{10}, "The number of transactions to return"},
|
{"count", RPCArg::Type::NUM, RPCArg::Default{10}, "The number of transactions to return"},
|
||||||
{"skip", RPCArg::Type::NUM, RPCArg::Default{0}, "The number of transactions to skip"},
|
{"skip", RPCArg::Type::NUM, RPCArg::Default{0}, "The number of transactions to skip"},
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# Copyright (c) 2014-2022 The Bitcoin Core developers
|
# Copyright (c) 2014-present The Bitcoin Core developers
|
||||||
# Distributed under the MIT software license, see the accompanying
|
# Distributed under the MIT software license, see the accompanying
|
||||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||||
"""Test the listtransactions API."""
|
"""Test the listtransactions API."""
|
||||||
|
@ -103,7 +103,6 @@ class ListTransactionsTest(BitcoinTestFramework):
|
||||||
txid = self.nodes[1].sendtoaddress(multisig["address"], 0.1)
|
txid = self.nodes[1].sendtoaddress(multisig["address"], 0.1)
|
||||||
self.generate(self.nodes[1], 1)
|
self.generate(self.nodes[1], 1)
|
||||||
assert_equal(len(self.nodes[0].listtransactions(label="watchonly", include_watchonly=True)), 1)
|
assert_equal(len(self.nodes[0].listtransactions(label="watchonly", include_watchonly=True)), 1)
|
||||||
assert_equal(len(self.nodes[0].listtransactions(dummy="watchonly", include_watchonly=True)), 1)
|
|
||||||
assert len(self.nodes[0].listtransactions(label="watchonly", count=100, include_watchonly=False)) == 0
|
assert len(self.nodes[0].listtransactions(label="watchonly", count=100, include_watchonly=False)) == 0
|
||||||
assert_array_result(self.nodes[0].listtransactions(label="watchonly", count=100, include_watchonly=True),
|
assert_array_result(self.nodes[0].listtransactions(label="watchonly", count=100, include_watchonly=True),
|
||||||
{"category": "receive", "amount": Decimal("0.1")},
|
{"category": "receive", "amount": Decimal("0.1")},
|
||||||
|
|
Loading…
Reference in a new issue