test-setup-new-chain.sh 778 B

1234567891011121314151617181920212223242526272829303132
  1. #!/usr/bin/env bash
  2. set -e
  3. SCRIPT_PATH="$(dirname "${BASH_SOURCE[0]}")"
  4. cd $SCRIPT_PATH
  5. # Custom sudo and treasury accounts - export them before start new chain
  6. # will be used to configre chainspec and override test framework defaults.
  7. export SUDO_ACCOUNT_URI=//Bob
  8. export SUDO_INITIAL_BALANCE=5000
  9. export TREASURY_ACCOUNT_URI=//Charlie
  10. export TREASURY_INITIAL_BALANCE=1000000000
  11. CONTAINER_ID=$(./run-test-node-docker.sh)
  12. function cleanup() {
  13. docker logs ${CONTAINER_ID} --tail 15
  14. docker-compose -f ../../docker-compose.yml down -v
  15. }
  16. trap cleanup EXIT
  17. sleep 3
  18. # Start the query node
  19. ../../query-node/start.sh
  20. # Display runtime version
  21. yarn workspace api-scripts tsnode-strict src/status.ts | grep Runtime
  22. # Init chain state
  23. ./run-test-scenario.sh setupNewChain