mirror of https://github.com/nucypher/nucypher.git
Don't use TesterBlockchain.ether_airdrop if it's already funded or can be done in the constructor
parent
09c0672dd0
commit
01c466554a
|
@ -68,7 +68,7 @@ class BlockchainInterface:
|
|||
compiler: SolidityCompiler = None) -> None:
|
||||
|
||||
"""
|
||||
A blockchain "network inerface"; The circumflex wraps entirely around the bounds of
|
||||
A blockchain "network interface"; The circumflex wraps entirely around the bounds of
|
||||
contract operations including compilation, deployment, and execution.
|
||||
|
||||
Filesystem Configuration Node Client EVM
|
||||
|
|
|
@ -39,8 +39,7 @@ def test_rapid_deployment():
|
|||
interface = BlockchainDeployerInterface(compiler=compiler,
|
||||
registry=registry,
|
||||
provider_uri='tester://pyevm')
|
||||
blockchain = TesterBlockchain(interface=interface, airdrop=False, test_accounts=4)
|
||||
blockchain.ether_airdrop(amount=TESTING_ETH_AIRDROP_AMOUNT)
|
||||
blockchain = TesterBlockchain(interface=interface, airdrop=True, test_accounts=4)
|
||||
origin, *everyone = blockchain.interface.w3.eth.accounts
|
||||
|
||||
deployer = Deployer(blockchain=blockchain,
|
||||
|
|
|
@ -25,7 +25,6 @@ from nucypher.utilities.sandbox.constants import TESTING_ETH_AIRDROP_AMOUNT
|
|||
@pytest.fixture(scope='module')
|
||||
def author(testerchain, three_agents):
|
||||
token_agent, miner_agent, policy_agent = three_agents
|
||||
token_agent.ether_airdrop(amount=TESTING_ETH_AIRDROP_AMOUNT)
|
||||
_origin, ursula, alice, *everybody_else = testerchain.interface.w3.eth.accounts
|
||||
author = PolicyAuthor(checksum_address=alice)
|
||||
return author
|
||||
|
|
|
@ -110,8 +110,7 @@ def deployed_blockchain():
|
|||
#
|
||||
# Blockchain
|
||||
#
|
||||
blockchain = TesterBlockchain(interface=interface, airdrop=False, test_accounts=5, poa=True)
|
||||
blockchain.ether_airdrop(amount=TESTING_ETH_AIRDROP_AMOUNT)
|
||||
blockchain = TesterBlockchain(interface=interface, airdrop=True, test_accounts=5, poa=True)
|
||||
origin, *everyone = blockchain.interface.w3.eth.accounts
|
||||
|
||||
#
|
||||
|
|
|
@ -341,11 +341,10 @@ def testerchain(solidity_compiler):
|
|||
provider_uri='tester://pyevm')
|
||||
|
||||
# Create the blockchain
|
||||
testerchain = TesterBlockchain(interface=deployer_interface, airdrop=False)
|
||||
testerchain = TesterBlockchain(interface=deployer_interface, airdrop=True)
|
||||
|
||||
origin, *everyone = testerchain.interface.w3.eth.accounts
|
||||
deployer_interface.deployer_address = origin # Set the deployer address from a freshly created test account
|
||||
testerchain.ether_airdrop(amount=TESTING_ETH_AIRDROP_AMOUNT)
|
||||
|
||||
yield testerchain
|
||||
testerchain.sever_connection()
|
||||
|
|
Loading…
Reference in New Issue