mirror of
https://github.com/faisalman/ua-parser-js.git
synced 2025-09-27 07:58:45 +03:00
Modify test scripts
This commit is contained in:
parent
a519d2b879
commit
df9144b493
@ -165,8 +165,12 @@
|
||||
],
|
||||
"scripts": {
|
||||
"build": "./script/build-dist.sh && ./script/build-module.js",
|
||||
"fuzz": "npx jazzer ./test/jazzer-fuzz-test.js --sync",
|
||||
"test": "npm run build && ./script/test-all.sh"
|
||||
"fuzz": "jazzer ./test/jazzer-fuzz-test.js --sync",
|
||||
"test": "./script/test-all.sh",
|
||||
"test:jshint": "jshint src && jshint script",
|
||||
"test:lockfile-lint": "npx lockfile-lint -p package-lock.json",
|
||||
"test:mocha": "mocha -R list test/mocha*js",
|
||||
"test:playwright": "playwright test"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/parser": "7.15.8",
|
||||
|
@ -1,21 +1,26 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
echo '
|
||||
- run build
|
||||
'
|
||||
npm run build || exit 1
|
||||
|
||||
echo '
|
||||
- lint js code
|
||||
'
|
||||
jshint src && jshint script || exit 1
|
||||
npm run test:jshint || exit 1
|
||||
|
||||
echo '
|
||||
- test using mocha
|
||||
'
|
||||
mocha -R list test/mocha*js || exit 1
|
||||
npm run test:mocha || exit 1
|
||||
|
||||
echo '
|
||||
- test using playwright
|
||||
'
|
||||
npx playwright test || exit 1
|
||||
npm run test:playwright || exit 1
|
||||
|
||||
echo '
|
||||
- lint lockfile
|
||||
'
|
||||
npx lockfile-lint -p package-lock.json || exit 1
|
||||
npm run test:lockfile-lint || exit 1
|
Loading…
x
Reference in New Issue
Block a user