Changeset 0.37.14 (#226)
Co-authored-by: gobha <jasafpro@gmail.com> Co-committed-by: gobha <jasafpro@gmail.com>
This commit is contained in:
@@ -202,10 +202,16 @@ jobs:
|
||||
- name: Syntax check (all JS)
|
||||
run: |
|
||||
echo "Checking JS syntax..."
|
||||
for f in src/js/*.js; do
|
||||
node --check "$f" || exit 1
|
||||
echo " ✓ $f"
|
||||
done
|
||||
err=0
|
||||
while IFS= read -r f; do
|
||||
# Feed file as module to node --check via stdin
|
||||
node --input-type=module --check < "$f" 2>/dev/null || {
|
||||
echo " ✗ $f"
|
||||
err=1
|
||||
}
|
||||
done < <(find src/js -name '*.js' -not -path '*/vendor/*' -not -path '*node_modules*')
|
||||
[ "$err" -eq 0 ] && echo " ✓ All JS files passed syntax check"
|
||||
exit $err
|
||||
|
||||
- name: Run frontend tests
|
||||
run: node --test src/js/__tests__/*.test.js
|
||||
|
||||
Reference in New Issue
Block a user