Skip to content

Commit

Permalink
test: add coverage to ensure the first arg of scantxoutset is needed
Browse files Browse the repository at this point in the history
Include a test that checks whether the first argument of
scantxoutset RPC call is required. The rpc call should fail if
the "start" argument is not provided.
  • Loading branch information
ismaelsadeeq committed Apr 5, 2023
1 parent 49b87bf commit 7e3d4f8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/functional/rpc_scantxoutset.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,9 @@ def run_test(self):
assert_equal(self.nodes[0].scantxoutset("status"), None)
assert_equal(self.nodes[0].scantxoutset("abort"), False)

# check that first arg is needed
assert_raises_rpc_error(-1, "scantxoutset \"action\" ( [scanobjects,...] )", self.nodes[0].scantxoutset)

# Check that second arg is needed for start
assert_raises_rpc_error(-1, "scanobjects argument is required for the start action", self.nodes[0].scantxoutset, "start")

Expand Down

0 comments on commit 7e3d4f8

Please sign in to comment.