From 0bbf99dabf690edb0683fcdbef6c32494e244f3e Mon Sep 17 00:00:00 2001 From: Sattvik Chakravarthy Date: Thu, 21 Nov 2024 18:24:17 +0530 Subject: [PATCH] fix: mocha --- .circleci/setupAndTestWithAuthReact.sh | 4 +--- .circleci/setupAndTestWithAuthReactWithDjango.sh | 4 +--- .circleci/setupAndTestWithAuthReactWithFlask.sh | 4 +--- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/.circleci/setupAndTestWithAuthReact.sh b/.circleci/setupAndTestWithAuthReact.sh index e04d4b55..4ad0496e 100755 --- a/.circleci/setupAndTestWithAuthReact.sh +++ b/.circleci/setupAndTestWithAuthReact.sh @@ -69,8 +69,6 @@ mkdir -p ~/test_report/logs mkdir -p ~/test_report/react-logs mkdir -p ~/test_report/screenshots -npm i -g mocha - echo "Running tests with React 18" # Run node server in background. if [[ "${SERVER_STARTED}" != "true" ]]; then @@ -103,7 +101,7 @@ if ! [[ -z "${CI}" ]]; then echo "Selected spec files: $SPEC_FILES, $CIRCLE_NODE_TOTAL/$CIRCLE_NODE_INDEX" fi -SCREENSHOT_ROOT=~/test_report/screenshots APP_SERVER=$apiPort TEST_MODE=testing mocha --bail=$BAIL --require @babel/register --require test/test.mocha.env --timeout 40000 --no-config $SPEC_FILES +SCREENSHOT_ROOT=~/test_report/screenshots APP_SERVER=$apiPort TEST_MODE=testing npx mocha --bail=$BAIL --require @babel/register --require test/test.mocha.env --timeout 40000 --no-config $SPEC_FILES testPassed=$?; if [[ $testPassed -ne 0 ]] diff --git a/.circleci/setupAndTestWithAuthReactWithDjango.sh b/.circleci/setupAndTestWithAuthReactWithDjango.sh index b666ab5f..6c3f259f 100755 --- a/.circleci/setupAndTestWithAuthReactWithDjango.sh +++ b/.circleci/setupAndTestWithAuthReactWithDjango.sh @@ -71,8 +71,6 @@ mkdir -p ~/test_report/logs mkdir -p ~/test_report/react-logs mkdir -p ~/test_report/screenshots -npm i -g mocha - echo "Running tests with React 18" # Run node server in background. if [[ "${SERVER_STARTED}" != "true" ]]; then @@ -105,7 +103,7 @@ if ! [[ -z "${CI}" ]]; then echo "Selected spec files: $SPEC_FILES, $CIRCLE_NODE_TOTAL/$CIRCLE_NODE_INDEX" fi -SCREENSHOT_ROOT=~/test_report/screenshots APP_SERVER=$apiPort TEST_MODE=testing mocha --bail=$BAIL --require @babel/register --require test/test.mocha.env --timeout 40000 --no-config $SPEC_FILES +SCREENSHOT_ROOT=~/test_report/screenshots APP_SERVER=$apiPort TEST_MODE=testing npx mocha --bail=$BAIL --require @babel/register --require test/test.mocha.env --timeout 40000 --no-config $SPEC_FILES testPassed=$?; if [[ $testPassed -ne 0 ]] diff --git a/.circleci/setupAndTestWithAuthReactWithFlask.sh b/.circleci/setupAndTestWithAuthReactWithFlask.sh index 245ae73e..922137f8 100755 --- a/.circleci/setupAndTestWithAuthReactWithFlask.sh +++ b/.circleci/setupAndTestWithAuthReactWithFlask.sh @@ -71,8 +71,6 @@ mkdir -p ~/test_report/logs mkdir -p ~/test_report/react-logs mkdir -p ~/test_report/screenshots -npm i -g mocha - echo "Running tests with React 18" # Run node server in background. if [[ "${SERVER_STARTED}" != "true" ]]; then @@ -105,7 +103,7 @@ if ! [[ -z "${CI}" ]]; then echo "Selected spec files: $SPEC_FILES, $CIRCLE_NODE_TOTAL/$CIRCLE_NODE_INDEX" fi -SCREENSHOT_ROOT=~/test_report/screenshots APP_SERVER=$apiPort TEST_MODE=testing mocha --bail=$BAIL --require @babel/register --require test/test.mocha.env --timeout 40000 --no-config $SPEC_FILES +SCREENSHOT_ROOT=~/test_report/screenshots APP_SERVER=$apiPort TEST_MODE=testing npx mocha --bail=$BAIL --require @babel/register --require test/test.mocha.env --timeout 40000 --no-config $SPEC_FILES testPassed=$?; if [[ $testPassed -ne 0 ]]