Skip to content

Commit

Permalink
Merge ElementsProject#272: Fix confidential test to not assume fee ou…
Browse files Browse the repository at this point in the history
…tput will be last of 3

3059856 Fix confidential test to not assume fee output will be last of 3 (Gregory Sanders)
  • Loading branch information
instagibbs committed Sep 26, 2017
2 parents cf854f1 + 3059856 commit 69fa8dd
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions qa/rpc-tests/confidential_transactions.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,14 +167,13 @@ def run_test(self):
self.nodes[0].generate(101)
self.sync_all()

txout0 = self.nodes[0].gettxout(txid, 0)
txout1 = self.nodes[0].gettxout(txid, 1)

if "asset" in txout0:
assert_equal(txout0["asset"], decodedtx["vout"][0]["asset"])
elif "asset" in txout1:
assert_equal(txout1["asset"], decodedtx["vout"][1]["asset"])
else:
unblindfound = False
for i in range(len(decodedtx["vout"])):
txout = self.nodes[0].gettxout(txid, i)
if txout is not None and "asset" in txout:
unblindfound = True

if unblindfound == False:
raise Exception("No unconfidential output detected when one should exist")

node0 -= value4
Expand Down

0 comments on commit 69fa8dd

Please sign in to comment.