Skip to content

Latest commit

 

History

History

e2e-tests

E2E Tests

End-to-end tests that run on a zombienet testnet.

NOTE: tested using polkadot v1.4.0

Setup

To setup the testing environment you need to first download the polkadot, polkadot-execute-worker, polkadot-prepare-worker and polkadot-parachain from the polkadot-sdk release page, as well as the trappist-node from its release page, and place them in the ../zombienet/bin/ folder.

You also need to have the latest zombienet executable in the ../zombienet/ folder, which you can download from here.

Launching zombienet

To launch the zombienet run the following commands:

$ yarn build && yarn e2e:build

Then run:

$ yarn e2e:zombienet

And this will launch the zombienet using the config file located in the ../zombienet/ directory. Once it finished its setup, you can proceed to the following step.

Launching the tests

For testing, we provide 4 options:

  • Testing liquidity tokens transfers with the command yarn e2e:liquidity-assets.
  • Testing foreign assets transfers with the command yarn e2e:foreign-assets.
  • Testing local transferss with the command yarn e2e:local.
  • Testing assets transfers with the command yarn e2e:assets.

Each of these commands will run the appropiate script to setup the basics, located in ../scripts/. Wait for it to finish setting up the testing environment, and then go through the tests indicated in the ./tests/index.ts file for the chosen option.

After each testing suite has been completed, it's recommended to restart the zombienet before running another test suite.