-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tests must be run against different chain configurations (#91)
* tests must be run against different chain configurations * compose args order matters * x bit not set on auction tests shell script * always run docker compose down... possibly to avoid insufficient funds error after a failed run * add arg to docker compose down for auction and nameservice-expiry * switch to main branch
- Loading branch information
1 parent
15c9ade
commit c227a38
Showing
7 changed files
with
104 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
services: | ||
laconicd: | ||
restart: unless-stopped | ||
image: cerc-io/laconicd:local-test | ||
environment: | ||
- TEST_AUCTION_ENABLED=true | ||
command: ["sh", "/docker-entrypoint-scripts.d/create-fixturenet.sh"] | ||
volumes: | ||
- ../../init.sh:/docker-entrypoint-scripts.d/create-fixturenet.sh | ||
healthcheck: | ||
test: ["CMD", "curl", "-v", "http://127.0.0.1:6060"] | ||
interval: 1s | ||
timeout: 5s | ||
retries: 30 | ||
ports: | ||
- "6060" | ||
- "26657" | ||
- "26656" | ||
- "9473" | ||
- "8545" | ||
- "8546" | ||
- "9090" | ||
- "9091" | ||
- "1317" | ||
|
||
sdk-test-runner: | ||
image: cerc-io/laconic-sdk-tester:local-test | ||
depends_on: | ||
laconicd: | ||
condition: service_healthy | ||
command: tail -F /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
services: | ||
laconicd: | ||
restart: unless-stopped | ||
image: cerc-io/laconicd:local-test | ||
environment: | ||
- TEST_REGISTRY_EXPIRY=true | ||
command: ["sh", "/docker-entrypoint-scripts.d/create-fixturenet.sh"] | ||
volumes: | ||
- ../../init.sh:/docker-entrypoint-scripts.d/create-fixturenet.sh | ||
healthcheck: | ||
test: ["CMD", "curl", "-v", "http://127.0.0.1:6060"] | ||
interval: 1s | ||
timeout: 5s | ||
retries: 30 | ||
ports: | ||
- "6060" | ||
- "26657" | ||
- "26656" | ||
- "9473" | ||
- "8545" | ||
- "8546" | ||
- "9090" | ||
- "9091" | ||
- "1317" | ||
|
||
sdk-test-runner: | ||
image: cerc-io/laconic-sdk-tester:local-test | ||
depends_on: | ||
laconicd: | ||
condition: service_healthy | ||
command: tail -F /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/usr/bin/env bash | ||
if [ -n "$CERC_SCRIPT_DEBUG" ]; then | ||
set -x | ||
fi | ||
# Get the key from laconicd | ||
laconicd_key=$( docker compose exec laconicd echo y | docker compose exec laconicd laconicd keys export mykey --unarmored-hex --unsafe ) | ||
# Set parameters for the test suite | ||
cosmos_chain_id=laconic_9000-1 | ||
laconicd_rest_endpoint=http://laconicd:1317 | ||
laconicd_gql_endpoint=http://laconicd:9473/api | ||
# Run tests | ||
docker network inspect sdk_tests_default | ||
sleep 30s | ||
docker logs sdk_tests-laconicd-1 | ||
|
||
docker compose exec sdk-test-runner sh -c "COSMOS_CHAIN_ID=${cosmos_chain_id} LACONICD_REST_ENDPOINT=${laconicd_rest_endpoint} LACONICD_GQL_ENDPOINT=${laconicd_gql_endpoint} PRIVATE_KEY=${laconicd_key} yarn test:auctions" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters