aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtests/functional_tests/blockchain.py3
-rwxr-xr-xtests/functional_tests/cold_signing.py3
-rwxr-xr-xtests/functional_tests/get_output_distribution.py3
-rwxr-xr-xtests/functional_tests/mining.py3
-rwxr-xr-xtests/functional_tests/multisig.py3
-rwxr-xr-xtests/functional_tests/proofs.py3
-rwxr-xr-xtests/functional_tests/speed.py3
-rwxr-xr-xtests/functional_tests/transfer.py3
-rwxr-xr-xtests/functional_tests/txpool.py3
-rwxr-xr-xtests/functional_tests/wallet.py3
10 files changed, 20 insertions, 10 deletions
diff --git a/tests/functional_tests/blockchain.py b/tests/functional_tests/blockchain.py
index 92857eae3..324af624a 100755
--- a/tests/functional_tests/blockchain.py
+++ b/tests/functional_tests/blockchain.py
@@ -53,7 +53,8 @@ class BlockchainTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def _test_generateblocks(self, blocks):
diff --git a/tests/functional_tests/cold_signing.py b/tests/functional_tests/cold_signing.py
index a722d8927..f915df77a 100755
--- a/tests/functional_tests/cold_signing.py
+++ b/tests/functional_tests/cold_signing.py
@@ -45,7 +45,8 @@ class ColdSigningTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def create(self, idx):
diff --git a/tests/functional_tests/get_output_distribution.py b/tests/functional_tests/get_output_distribution.py
index 93822e90a..077b094ba 100755
--- a/tests/functional_tests/get_output_distribution.py
+++ b/tests/functional_tests/get_output_distribution.py
@@ -44,7 +44,8 @@ class GetOutputDistributionTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def create(self):
diff --git a/tests/functional_tests/mining.py b/tests/functional_tests/mining.py
index 360f2763d..f1b91e8fc 100755
--- a/tests/functional_tests/mining.py
+++ b/tests/functional_tests/mining.py
@@ -53,7 +53,8 @@ class MiningTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def create(self):
diff --git a/tests/functional_tests/multisig.py b/tests/functional_tests/multisig.py
index 7d73a5d71..e0d8b06a4 100755
--- a/tests/functional_tests/multisig.py
+++ b/tests/functional_tests/multisig.py
@@ -81,7 +81,8 @@ class MultisigTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def mine(self, address, blocks):
diff --git a/tests/functional_tests/proofs.py b/tests/functional_tests/proofs.py
index f443ba795..7beb3ec6e 100755
--- a/tests/functional_tests/proofs.py
+++ b/tests/functional_tests/proofs.py
@@ -50,7 +50,8 @@ class ProofsTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def mine(self, address, blocks):
diff --git a/tests/functional_tests/speed.py b/tests/functional_tests/speed.py
index 5858c5803..591c98ec1 100755
--- a/tests/functional_tests/speed.py
+++ b/tests/functional_tests/speed.py
@@ -50,7 +50,8 @@ class SpeedTest():
def reset(self):
print 'Resetting blockchain'
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def run_test(self):
diff --git a/tests/functional_tests/transfer.py b/tests/functional_tests/transfer.py
index baefd033e..9cb03741f 100755
--- a/tests/functional_tests/transfer.py
+++ b/tests/functional_tests/transfer.py
@@ -56,7 +56,8 @@ class TransferTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def create(self):
diff --git a/tests/functional_tests/txpool.py b/tests/functional_tests/txpool.py
index fd74ae129..27ae89764 100755
--- a/tests/functional_tests/txpool.py
+++ b/tests/functional_tests/txpool.py
@@ -46,7 +46,8 @@ class TransferTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def create(self):
diff --git a/tests/functional_tests/wallet.py b/tests/functional_tests/wallet.py
index 2240f96ec..85f6a4955 100755
--- a/tests/functional_tests/wallet.py
+++ b/tests/functional_tests/wallet.py
@@ -74,7 +74,8 @@ class WalletTest():
def reset(self):
print('Resetting blockchain')
daemon = Daemon()
- daemon.pop_blocks(1000)
+ res = daemon.get_height()
+ daemon.pop_blocks(res.height - 1)
daemon.flush_txpool()
def create(self):