File: functional.sh

package info (click to toggle)
node-terser 5.38.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 4,156 kB
  • sloc: javascript: 99,692; makefile: 52; perl: 48; sh: 13
file content (23 lines) | stat: -rwxr-xr-x 523 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/bash

set -exuo pipefail

workdir=$(pwd)
# for tests that need terser-under-test path and @terser/require-terser
export TERSER_PATH="$workdir"

# build terser
npm run build

# grab the functional tests
mkdir -p terser-functional-tests
cd terser-functional-tests
git checkout . || true
git clone https://github.com/terser/terser-functional-tests --depth 1 . || true
git pull

# install packages and link terser in (can't npm link .., it crashes)
npm ci
(cd node_modules && rm -rf terser && ln -s ../.. terser)

npm t