Skip to content

Commit

Permalink
Format Python
Browse files Browse the repository at this point in the history
  • Loading branch information
Bushstar committed Sep 12, 2023
1 parent 22d068f commit e4fd610
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 9 deletions.
4 changes: 2 additions & 2 deletions test/functional/feature_evm.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,13 +255,13 @@ def evm_gov_vars(self):
-32600,
"Cannot be set before NextNetworkUpgradeHeight",
self.nodes[0].setgov,
{"ATTRIBUTES": {"v0/params/feature/evm": "true"}}
{"ATTRIBUTES": {"v0/params/feature/evm": "true"}},
)
assert_raises_rpc_error(
-32600,
"Cannot be set before NextNetworkUpgradeHeight",
self.nodes[0].setgov,
{"ATTRIBUTES": {"v0/params/feature/transferdomain": "true"}}
{"ATTRIBUTES": {"v0/params/feature/transferdomain": "true"}},
)
assert_raises_rpc_error(
-32600,
Expand Down
1 change: 1 addition & 0 deletions test/functional/feature_evm_logs.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
from test_framework.evm_key_pair import EvmKeyPair
from web3._utils.events import get_event_data


class EVMTestLogs(DefiTestFramework):
def set_test_params(self):
self.num_nodes = 1
Expand Down
1 change: 0 additions & 1 deletion test/functional/feature_evm_rollback.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,6 @@ def test_rollback_transactions(self):
def run_test(self):
self.setup()


self.nodes[0].transferdomain(
[
{
Expand Down
3 changes: 2 additions & 1 deletion test/functional/feature_evm_transaction_replacement.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,8 @@ def should_prioritize_transaction_with_the_higher_gas_price(self):
-32001,
"lower fee as existing mempool entry",
self.send_transaction,
gasPrices[0], count
gasPrices[0],
count,
)

self.nodes[0].generate(1)
Expand Down
11 changes: 7 additions & 4 deletions test/functional/feature_evm_transferdomain.py
Original file line number Diff line number Diff line change
Expand Up @@ -908,10 +908,12 @@ def invalid_transfer_evm_dvm_after_evm_tx(self):
self.valid_transfer_dvm_evm()

balance = self.nodes[0].eth_getBalance(self.eth_address)
assert_equal(balance, "0x56bc75e2d63100000") # 100 DFI
erc55_address = self.nodes[0].getnewaddress('', 'erc55')
assert_equal(balance, "0x56bc75e2d63100000") # 100 DFI
erc55_address = self.nodes[0].getnewaddress("", "erc55")

tx1 = self.nodes[0].evmtx(self.eth_address, 0, 21, 21001, erc55_address, 50) # Spend half balance
tx1 = self.nodes[0].evmtx(
self.eth_address, 0, 21, 21001, erc55_address, 50
) # Spend half balance

# Transfer 100 DFI from EVM to DVM
tx2 = transfer_domain(
Expand Down Expand Up @@ -947,7 +949,8 @@ def run_test(self):

self.valid_transfer_to_evm_then_move_then_back_to_dvm()

self.invalid_transfer_evm_dvm_after_evm_tx() # TODO assert behaviour here. transferdomain shouldn't be kept in mempool since its nonce will never be valid
self.invalid_transfer_evm_dvm_after_evm_tx() # TODO assert behaviour here. transferdomain shouldn't be kept in mempool since its nonce will never be valid


if __name__ == "__main__":
EVMTest().main()
6 changes: 5 additions & 1 deletion test/functional/feature_evm_vmmap_rpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,11 @@ def vmmap_transfer_domain(self):
tx = self.nodes[0].transferdomain(
[
{
"src": {"address": self.ethAddress, "amount": "100@DFI", "domain": 3},
"src": {
"address": self.ethAddress,
"amount": "100@DFI",
"domain": 3,
},
"dst": {
"address": self.address,
"amount": "100@DFI",
Expand Down

0 comments on commit e4fd610

Please sign in to comment.