Rehabilitate tests for cic-eth
This commit is contained in:
@@ -40,7 +40,9 @@ def test_filter_gas(
|
||||
foo_token,
|
||||
token_registry,
|
||||
register_lookups,
|
||||
celery_session_worker,
|
||||
register_tokens,
|
||||
#celery_session_worker,
|
||||
celery_worker,
|
||||
cic_registry,
|
||||
):
|
||||
|
||||
@@ -69,7 +71,7 @@ def test_filter_gas(
|
||||
tx = Tx(tx_src, block=block)
|
||||
tx.apply_receipt(rcpt)
|
||||
t = fltr.filter(eth_rpc, block, tx, db_session=init_database)
|
||||
assert t == None
|
||||
assert t.get() == None
|
||||
|
||||
nonce_oracle = RPCNonceOracle(contract_roles['CONTRACT_DEPLOYER'], eth_rpc)
|
||||
c = TokenUniqueSymbolIndex(default_chain_spec, signer=eth_signer, nonce_oracle=nonce_oracle)
|
||||
|
||||
@@ -288,7 +288,6 @@ def test_fix_nonce(
|
||||
|
||||
init_database.commit()
|
||||
|
||||
logg.debug('!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!')
|
||||
txs = get_nonce_tx_local(default_chain_spec, 3, agent_roles['ALICE'], session=init_database)
|
||||
ks = txs.keys()
|
||||
assert len(ks) == 2
|
||||
|
||||
@@ -191,11 +191,17 @@ def test_tokens(
|
||||
break
|
||||
|
||||
api_param = str(uuid.uuid4())
|
||||
fp = os.path.join(CallbackTask.mmap_path, api_param)
|
||||
f = open(fp, 'wb+')
|
||||
f.write(b'\x00')
|
||||
f.close()
|
||||
|
||||
api = Api(str(default_chain_spec), queue=None, callback_param=api_param, callback_task='cic_eth.pytest.mock.callback.test_callback')
|
||||
t = api.tokens(['BAR'], proof=[[bar_token_declaration]])
|
||||
r = t.get()
|
||||
logg.debug('rr {} {}'.format(r, t.children))
|
||||
|
||||
|
||||
while True:
|
||||
fp = os.path.join(CallbackTask.mmap_path, api_param)
|
||||
try:
|
||||
|
||||
@@ -45,7 +45,7 @@ def test_task_gas_limit(
|
||||
eth_signer,
|
||||
default_chain_spec,
|
||||
agent_roles,
|
||||
celery_worker,
|
||||
celery_session_worker,
|
||||
):
|
||||
rpc = RPCConnection.connect(default_chain_spec, 'default')
|
||||
gas_oracle = BaseTask().create_gas_oracle(rpc)
|
||||
|
||||
Reference in New Issue
Block a user