Skip to content

Commit

Permalink
Add a warning to the test262 test runner script if the submodule hasn't
Browse files Browse the repository at this point in the history
been initialized.
  • Loading branch information
12wrigja authored and ptomato committed Oct 6, 2021
1 parent 07ea694 commit 429273e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions test/test262.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
#!/bin/bash
# Note that this script is only expected to be run via `npm run test262`, not by
# being manually executed.
set -e

TESTS=${@:-"**/*.js"}
Expand All @@ -11,6 +13,11 @@ else
fi
if [ $threads -gt 8 ]; then threads=8; fi

if [ ! -d "$(dirname "$0")"/../test262/test/ ]; then
echo "Missing Test262 directory. Try initializing the submodule with 'git submodule init && git submodule update'";
exit 1;
fi

cd "$(dirname "$0")"/../test262/test/
test262-harness \
-t $threads \
Expand Down

0 comments on commit 429273e

Please sign in to comment.