Skip to content

Commit 6726be1

Browse files
committed
docs: port instructions from multichain-testing/README.md
1 parent 029bb89 commit 6726be1

File tree

1 file changed

+113
-0
lines changed

1 file changed

+113
-0
lines changed

e2e-testing/README.md

+113
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
# Starship
2+
3+
End-to-end testing environment for fully simulated chains, powered by [Starship](https://docs.cosmology.zone/starship).
4+
5+
## Configuration
6+
7+
The current commands will read from [`config.yaml`](./config.yaml) to build a multi-chain testing environment. Currently, the image includes `agoric`, `osmosis`, and `cosmoshub` chains and a hermes relayer between each.
8+
9+
The `agoric` software revision includes the vats necessary for building and testing orchestration applications:
10+
- vat-network
11+
- vat-ibc
12+
- vat-localchain
13+
- vat-transfer
14+
- vat-orchestration
15+
16+
## Initial Setup
17+
18+
Ensure you have Kubernetes available. See https://docs.cosmology.zone/starship/get-started/step-2.
19+
20+
The following will install `kubectl`, `kind`, `helm`, and `yq` as needed:
21+
22+
```sh
23+
make clean setup
24+
```
25+
26+
## Getting Started
27+
28+
You can start everything with a single command:
29+
30+
```sh
31+
make start
32+
```
33+
34+
This command will:
35+
1. Install the Helm chart and start the Starship service
36+
2. Wait for all pods to be ready
37+
3. Set up port forwarding
38+
4. Fund the provision pool
39+
5. Override the chain registry
40+
41+
The process may take 7-12 minutes to complete. You'll see status updates as the pods come online.
42+
43+
Alternatively, you can run the steps individually:
44+
45+
```sh
46+
# install helm chart and start starship service
47+
make install
48+
49+
# wait for all pods to spin up
50+
make wait-for-pods
51+
52+
# expose ports on your local machine (useful for testing dapps)
53+
make port-forward
54+
55+
# set up Agoric testing environment
56+
make fund-provision-pool override-chain-registry register-bank-assets
57+
```
58+
59+
If you get an error like "connection refused", you need to wait longer, until all the pods are Running.
60+
61+
## Cleanup
62+
63+
```sh
64+
# stop the containers and port-forwarding
65+
make stop
66+
67+
# delete the clusters
68+
make clean
69+
```
70+
71+
## Logs
72+
73+
You can use the following commands to view logs:
74+
75+
```sh
76+
# agoric slogfile
77+
make tail-slog
78+
79+
# agoric validator logs
80+
kubectl logs agoriclocal-genesis-0 --container=validator --follow
81+
82+
# relayer logs
83+
kubectl logs hermes-agoric-gaia-0 --container=relayer --follow
84+
kubectl logs hermes-osmosis-gaia-0 --container=relayer --follow
85+
```
86+
87+
## Agoric Smart Wallet
88+
89+
For the steps below, you must import a key to `agd` or create a new one.
90+
91+
```bash
92+
# create a `user1` key from a random seed
93+
kubectl exec -i agoriclocal-genesis-0 -c validator -- agd keys add user1
94+
95+
# get the newly created address
96+
ADDR=$(kubectl exec -i agoriclocal-genesis-0 -c validator -- agd keys show user1 -a)
97+
98+
# fund the wallet with some tokens
99+
make fund-wallet COIN=20000000ubld ADDR=$ADDR
100+
101+
# provision the smart wallet
102+
make provision-smart-wallet ADDR=$ADDR
103+
```
104+
105+
## Chain Registry
106+
107+
These only work if you've done `make port-forward`.
108+
109+
- http://localhost:8081/chains/agoriclocal
110+
- http://localhost:8081/chains/osmosislocal
111+
- http://localhost:8081/chains/gaialocal
112+
- http://localhost:8081/chains/agoriclocal/keys
113+
- http://localhost:8081/ibc

0 commit comments

Comments
 (0)