Skip to content

Commit

Permalink
Find jest path using which
Browse files Browse the repository at this point in the history
`npm bin` was removed: npm/cli#5459

Signed-off-by: Andrew Haines <[email protected]>
  • Loading branch information
haines committed Nov 10, 2022
1 parent af75d5c commit 44a0b7f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/test/scripts/jest
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@ set -o errexit
set -o nounset
set -o pipefail

jest=$(which jest)

node_version=$(node --version)
npm_bin=$(npm bin)

node_command=(node)

Expand All @@ -16,4 +17,4 @@ esac

export NODE_EXTRA_CA_CERTS=servers/tmp/certificates/server.root.crt

exec "${node_command[@]}" "${npm_bin}/jest" "$@"
exec "${node_command[@]}" "${jest}" "$@"

0 comments on commit 44a0b7f

Please sign in to comment.