Skip to content

Commit

Permalink
use hard kill on nodeos
Browse files Browse the repository at this point in the history
  • Loading branch information
taokayan committed Sep 23, 2024
1 parent ab17671 commit 6e5b6c7
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 11 deletions.
8 changes: 6 additions & 2 deletions tests/nodeos_eos_evm_different_token_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -1029,7 +1029,11 @@ def get_block(num):
if eosEvmMinerPOpen is not None:
Utils.Print("killing evm-miner")
eosEvmMinerPOpen.kill()
TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails)

Utils.Print("killing nodeos")
for node in cluster.nodes:
node.kill(signal.SIGKILL)
if len(cluster.nodes) and cluster.biosNode != cluster.nodes[0]:
cluster.biosNode.kill(signal.SIGKILL)

exitCode = 0 if testSuccessful else 1
exit(exitCode)
7 changes: 6 additions & 1 deletion tests/nodeos_eos_evm_gasparam_fork_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -1107,7 +1107,12 @@ def makeReservedEvmAddress(account):
if wsproxy is not None:
Utils.Print("killing web-socket proxy")
wsproxy.kill()
TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails)
Utils.Print("killing nodeos")
for node in cluster.nodes:
node.kill(signal.SIGKILL)
if len(cluster.nodes) and cluster.biosNode != cluster.nodes[0]:
cluster.biosNode.kill(signal.SIGKILL)
#TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails)

exitCode = 0 if testSuccessful else 1
exit(exitCode)
9 changes: 6 additions & 3 deletions tests/nodeos_eos_evm_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -1140,8 +1140,11 @@ def get_block(num):
if eosEvmMinerPOpen is not None:
Utils.Print("killing evm-miner")
eosEvmMinerPOpen.kill()
Utils.Print("shutting down cluster")
TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails)

Utils.Print("killing nodeos")
for node in cluster.nodes:
node.kill(signal.SIGKILL)
if len(cluster.nodes) and cluster.biosNode != cluster.nodes[0]:
cluster.biosNode.kill(signal.SIGKILL)

exitCode = 0 if testSuccessful else 1
exit(exitCode)
8 changes: 6 additions & 2 deletions tests/nodeos_eos_evm_ws_test_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -796,7 +796,11 @@ def makeReservedEvmAddress(account):
if wsproxy is not None:
Utils.Print("killing web-socket proxy")
wsproxy.kill()
TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails)

Utils.Print("killing nodeos")
for node in cluster.nodes:
node.kill(signal.SIGKILL)
if len(cluster.nodes) and cluster.biosNode != cluster.nodes[0]:
cluster.biosNode.kill(signal.SIGKILL)

exitCode = 0 if testSuccessful else 1
exit(exitCode)
9 changes: 6 additions & 3 deletions tests/nodeos_eos_evm_ws_test_fork.py
Original file line number Diff line number Diff line change
Expand Up @@ -1104,9 +1104,12 @@ def makeReservedEvmAddress(account):
if wsproxy is not None:
Utils.Print("killing web-socket proxy")
wsproxy.kill()
Utils.Print("shutting down cluster")
TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails)

Utils.Print("killing nodeos")
for node in cluster.nodes:
node.kill(signal.SIGKILL)
if len(cluster.nodes) and cluster.biosNode != cluster.nodes[0]:
cluster.biosNode.kill(signal.SIGKILL)

Utils.Print("exit eos evm web-socket fork test")
exitCode = 0 if testSuccessful else 1
exit(exitCode)

0 comments on commit 6e5b6c7

Please sign in to comment.