Revision 4aaf141ddb0617aedc16f3652b0feee0069bc5be authored by Leon Sorokin on 13 May 2021, 07:33:11 UTC, committed by GitHub on 13 May 2021, 07:33:11 UTC
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
1 parent 6014551
Raw File
run-suite
#!/bin/bash
set -xeo pipefail

. e2e/variables

HOST=${HOST:-$DEFAULT_HOST}
PORT=${PORT:-$DEFAULT_PORT}

echo -e "Starting Cypress scenarios"

CMD="start"
PARAMS=""
SLOWMO=0
URL=${BASE_URL:-"http://$HOST:$PORT"}
SUITE=${SUITE:-$DEFAULT_SUITE}

if [ "$1" == "debug" ]; then
    echo -e "Debug mode"
    SLOWMO=1
    PARAMS="--headed --no-exit"
fi

if [ "$1" == "dev" ]; then
    echo "Dev mode"
    CMD="open"
fi

cd packages/grafana-e2e

yarn $CMD --env BASE_URL=$URL,SLOWMO=$SLOWMO \
  --config defaultCommandTimeout=30000,integrationFolder=../../e2e/$SUITE/specs,screenshotsFolder=../../e2e/$SUITE/screenshots,videosFolder=../../e2e/$SUITE/videos,fileServerFolder=./cypress,viewportWidth=1920,viewportHeight=1080,trashAssetsBeforeRuns=false \
  $PARAMS
back to top