Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
mmsqe committed Oct 9, 2024
1 parent de587a8 commit 6a98f8a
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
* [#1617](https://github.com/crypto-org-chain/cronos/pull/1617) Fix unsuppored sign mode SIGN_MODE_TEXTUAL for bank transfer.
* [#1621](https://github.com/crypto-org-chain/cronos/pull/1621), [1630](https://github.com/crypto-org-chain/cronos/pull/1630) Update ethermint to the fix of broken opBlockhash and tx validation.
* [#1623](https://github.com/crypto-org-chain/cronos/pull/1623) Ensure expedited related gov params pass the basic validation.
* [#1633](https://github.com/crypto-org-chain/cronos/pull/1633) Align acknowledgement with underlying_app_success when ack packet not does not succeed.

*Sep 13, 2024*

Expand Down
23 changes: 22 additions & 1 deletion integration_tests/test_ica_precompile.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,6 @@ def test_sc_call(ibc, order):
signer=signer,
contract_addr=contract_addr,
)
balance = funds_ica(cli_host, ica_address, signer=signer)
assert tcontract.caller.getAccount() == addr
assert (
tcontract.functions.callQueryAccount(connid, contract_addr).call()
Expand Down Expand Up @@ -306,6 +305,7 @@ def submit_msgs_ro(func, str):
expected_seq,
contract.events.SubmitMsgsResult,
channel_id,
need_wait=False,
signer=signer,
)
submit_msgs_ro(tcontract.functions.delegateSubmitMsgs, str)
Expand All @@ -314,6 +314,27 @@ def submit_msgs_ro(func, str):
wait_for_status_change(tcontract, channel_id, last_seq)
status = tcontract.caller.getStatus(channel_id, last_seq)
assert expected_seq == last_seq
assert status == Status.FAIL
wait_for_packet_log(start, packet_event, channel_id, last_seq, status)

expected_seq += 1
balance = funds_ica(cli_host, ica_address, signer=signer)
start = w3.eth.get_block_number()
str, diff = submit_msgs(
ibc,
tcontract.functions.callSubmitMsgs,
data,
ica_address,
False,
expected_seq,
contract.events.SubmitMsgsResult,
channel_id,
signer=signer,
)
last_seq = tcontract.caller.getLastSeq()
wait_for_status_change(tcontract, channel_id, last_seq)
status = tcontract.caller.getStatus(channel_id, last_seq)
assert expected_seq == last_seq
assert status == Status.SUCCESS
wait_for_packet_log(start, packet_event, channel_id, last_seq, status)
balance -= diff
Expand Down

0 comments on commit 6a98f8a

Please sign in to comment.