Refactor participate_tx

This commit is contained in:
tecnovert
2019-07-27 21:50:50 +02:00
parent 4a07c891f6
commit 7ccf191192
7 changed files with 100 additions and 82 deletions

View File

@@ -371,7 +371,7 @@ class Test(unittest.TestCase):
time.sleep(1)
bid = swap_client.getBid(bid_id)
if (initiate_state is None or bid.getITxState() == initiate_state) \
and (participate_state is None or bid.participate_txn_state == participate_state):
and (participate_state is None or bid.getPTxState() == participate_state):
return
raise ValueError('wait_for_bid_tx_state timed out.')

View File

@@ -30,7 +30,7 @@ class Test(unittest.TestCase):
shutil.rmtree(test_path)
except Exception as ex:
logger.warning('tearDownClass %s', str(ex))
super(Test, cls).tearDownClass()
super(Test, self).tearDownClass()
def test(self):
testargs = ['basicswap-prepare', '-datadir=' + test_path]

View File

@@ -20,10 +20,8 @@ import sys
import time
import unittest
from unittest.mock import patch
from io import StringIO
import logging
import shutil
import json
import threading
import bin.basicswap_prepare as prepareSystem

View File

@@ -367,7 +367,7 @@ class Test(unittest.TestCase):
time.sleep(1)
bid = swap_client.getBid(bid_id)
if (initiate_state is None or bid.getITxState() == initiate_state) \
and (participate_state is None or bid.participate_txn_state == participate_state):
and (participate_state is None or bid.getPTxState() == participate_state):
return
raise ValueError('wait_for_bid_tx_state timed out.')