interchaintest

command module
v0.0.0-...-a1d3391 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

README

End to End Tests

The e2e tests are built using the interchaintest library by Strangelove. It runs multiple docker container validators, and lets you test IBC enabled smart contracts.

Running the tests locally

All contract tests are located in interchaintest/contract_test.go file. Currently, there are four tests in this file:

  • TestIcaContractChannelHandshake
  • TestIcaContractExecutionProto3JsonEncoding
  • TestIcaContractExecutionProtobufEncoding
  • TestIcaContractTimeoutPacket

(These three tests used to be one monolithic test, but they were split into three in order to run them in parallel in the CI.)

To run the tests locally, run the following commands from this directory:

cd interchaintest/
go test -v . -run TestWithContractTestSuite -testify.m $TEST_NAME

where $TEST_NAME is one of the four tests listed above.

Before running the tests, you must have built the optimized contract in the /artifacts directory. To do this, run the following command from the root of the repository:

cargo run-script optimize

In the CI

The tests are run in the github CI after every push to the main branch. See the github actions workflow for more details.

For some unknown reason, the timeout test sometimes fails in the CI (I'd say about 20-25% of the time). In this case, feel free to rerun the CI job.

About the tests

The tests are currently run on wasmd v0.40.2 and ibc-go v7.3.0's simd which implements json encoding feature for the interchain accounts module.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL