Browse Source

integration-tests: wait 10s for chain to startup

Mokhtar Naamani 4 years ago
parent
commit
ef088ee0be
3 changed files with 7 additions and 3 deletions
  1. 3 0
      query-node/run-tests.sh
  2. 3 3
      tests/network-tests/run-tests.sh
  3. 1 0
      utils/api-scripts/src/status.ts

+ 3 - 0
query-node/run-tests.sh

@@ -43,6 +43,9 @@ docker-compose up -d graphql-server
 # Start the joystream-node before the indexer
 docker-compose up -d joystream-node
 
+# Wait for chain to startup
+sleep 10
+
 # Starting up processor will bring up all services it depends on
 docker-compose up -d processor
 

+ 3 - 3
tests/network-tests/run-tests.sh

@@ -73,6 +73,9 @@ function cleanup() {
 
 trap cleanup EXIT
 
+echo "Waiting for chain to startup..."
+sleep 10
+
 if [ "$TARGET_RUNTIME" == "$RUNTIME" ]; then
   echo "Not Performing a runtime upgrade."
 else
@@ -95,7 +98,4 @@ fi
 # Display runtime version
 yarn workspace api-scripts tsnode-strict src/status.ts | grep Runtime
 
-echo "Waiting for chain to startup..."
-sleep 10
-
 ./run-test-scenario.sh $1

+ 1 - 0
utils/api-scripts/src/status.ts

@@ -20,6 +20,7 @@ async function main() {
       break
     } catch (err) {
       // failed to connect to node
+      console.error('Caught Error', err)
     }
 
     if (retry-- === 0) {