#!/bin/bash
# Run all sanity checks; exit non-zero if any failed.
set -euo pipefail
ROOT=$(cd "$(dirname "$0")" && pwd)
ec=0
for s in \
  check_helpers-running.sh \
  check_stack-health.sh \
  check_merchant-delays.sh \
  check_exchange-wirewatch.sh \
  check_settlement.sh
do
  echo ""
  echo "########## $s ##########"
  if bash "$ROOT/$s"; then
    echo "PASS $s"
  else
    echo "FAIL $s (exit $?)"
    ec=1
  fi
done
exit $ec
