Skip to content

Commit

Permalink
Add a failing test case for reissuance from an unblinded output (Elem…
Browse files Browse the repository at this point in the history
  • Loading branch information
shesek committed Jun 12, 2022
1 parent 03b8b0c commit e607d69
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions test/functional/feature_issuance.py
Original file line number Diff line number Diff line change
Expand Up @@ -500,5 +500,14 @@ def run_test(self):
txid = self.nodes[1].issueasset(0, 1, False)["txid"]
tx = self.nodes[1].getrawtransaction(txid, True)

# Test reissuing with a reissuance token spent from an unblinded output
# https://github.com/ElementsProject/elements/issues/259
issued = self.nodes[0].issueasset(0, Decimal('0.00000001'), False)
# Get a non-confidential address and send the (only) reissuance token to it
uc_addr = self.nodes[0].validateaddress(self.nodes[0].getnewaddress())["unconfidential"]
self.nodes[0].sendtoaddress(uc_addr, Decimal('0.00000001'), "", "", False, False, 1, "UNSET", False, issued["token"])
# This currently fails with 'JSONRPCException: Unable to blind the transaction properly. This should not happen. (-4)'
self.nodes[0].reissueasset(issued["asset"], 1)

if __name__ == '__main__':
IssuanceTest ().main ()

0 comments on commit e607d69

Please sign in to comment.