tokenbridge/oracle-e2e
Przemyslaw Rzad 8b010f887d
Consistent variable naming (#198)
* Add console.table

* First steps in validate script

* env rename

* Added parameter names

* Descriptions

* Print and configuration

* Added more parameters

* Rename gas oracle to gas supplier

* More changes

* Removed env examples for now

* RPC rename

* Bridge address rename

* More changes

* jobs

* Renames

* Typo

* jobs

* Changes

* jobs

* Changes

* Monitor changes

* jovs

* Typo

* Changes

* REACT_APP_ env prefix

* Typo

* Rollback changes

* Oracle deployment

* Defaults

* Monitor

* Naming

* Typo

* Typo

* Envs

* ui deployment

* ALl jobs

* Vars in ultimate

* Lint

* Lint

* Lint

* Another way to add REACT_APP prefixing

* Unnecessary mapping

* No output timeout

* No output timeout

* Got rid of ERC20_TOKEN_ADDRESS

* Configuration readme

* Configuration

* Prefixes

* timeout

* Docs

* Docs

* docs

* docs

* docs

* Roll back ERC20_TOKEN_ADDRESS for erc-to-erc

* Typo

* lint

* Rollback

* ROllback validator

* Rollback yarn.lock

* dai and wetc update

* Rollback ERC20_TOKEN_ADDRESS

* erc to native

* examples

* all jobs

* roll back

* roll back ERC20_TOKEN_ADDRESS: "0xdbeE25CbE97e4A5CC6c499875774dc7067E9426B"

* ui env example

* typo

* Allow rpc for ultimate

* Test

* ERC20_TOKEN_ADDRESS rollback

* Specify port

* React port

* All jobs

* cosmetics

* Values

* Restore erc20 token

* Rearrange example for easier comparision

* Rearrange ultimate for easier comparision

* Rearrange for easier comparision

* Refactor

* Conditional app styles

* Loading environment variables in react app

* Add missing vars for UI in wetc and dai

* Bring back test parameters readme

* Readme for monitor vars

* Reading environment variables in e2e-commons (#207)
2019-09-13 09:11:38 +02:00
..
test Consistent variable naming (#198) 2019-09-13 09:11:38 +02:00
.eslintrc E2E files linting (#117) 2019-07-02 15:12:57 +02:00
package.json Ultimate E2E tests (#158) 2019-07-26 10:14:25 +02:00
README.md Cosistent TokenBridge naming (#159) 2019-07-19 09:18:51 +02:00
run-tests.sh Common deploy 2019-06-04 09:11:56 +02:00

POA TokenBridge / Oracle-E2E

End to end tests for the POA TokenBridge Oracle.

Prerequisites

To run the tests you need to have Docker and Docker Compose installed. If you are on Linux, it's also recommended that you create a docker group and add your user to it, so that you can use the CLI without sudo.

Running

To run the bridge end-to-end tests, you just have to run:

./run-tests.sh

If this is the first time that you do this, it will take some time to build the docker images, but the next time they will be cached.

How it works

The script starts several containers and then use them to run the tests. These services are:

  • Two parity nodes with the InstanSeal engine, representing the home and foreign chains.
  • A Redis container.
  • A RabbitMQ container.
  • The bridge (without doing anything at first)
  • The container for the end-to-end tests (also without doing anything)

Afterwards, contracts will be deployed to the respective chains, all the bridge scripts will be executed (using the bridge service) and tests (using the e2e service) will be executed. The last process exit code will be used as the result of the testing suite.

Debugging

Sometimes you may need to look into what happened in each service after running the tests. For doing this, comment out the docker-compose down line in the run-tests.sh file, and all the containers will be kept running after the script finishes. Some things you can do:

  • Connect to the home chain using http://localhost:8541 as the URL.
  • Connect to the foreign chain using http://localhost:8542 as the URL.
  • Open the RabbitMQ Management service (go to http://localhost:15672 in the browser and log in with username/password guest/guest).
  • Inspect the logs using docker logs CONTAINER. You can obtain the container name with the docker ps command.