#!/bin/bash

set -euo pipefail

cd _examples/federation

./start.sh &

sleep 5
curl -s --connect-timeout 5 \
    --max-time 10 \
    --retry 5 \
    --retry-delay 5 \
    --retry-max-time 40 \
    --retry-connrefused \
    localhost:4003 > /dev/null

sleep 1

echo "### running jest integration spec"
./node_modules/.bin/jest --color

