fix: test commands

This commit is contained in:
lowlighter
2022-01-27 12:32:00 -05:00
parent dacbaef1a9
commit e53361de9e
2 changed files with 6 additions and 4 deletions

View File

@@ -23,7 +23,7 @@ jobs:
- name: Setup metrics - name: Setup metrics
run: npm ci run: npm ci
- name: Check contributions requirements - name: Check contributions requirements
run: npm test -- ci.test.js --noStackTrace run: npm run test-contrib
env: env:
PR_AUTHOR: ${{ github.event.pull_request.user.login }} PR_AUTHOR: ${{ github.event.pull_request.user.login }}
- name: Run linter - name: Run linter
@@ -47,7 +47,7 @@ jobs:
- name: Build lowlighter/metrics:${{ github.head_ref || 'master' }} - name: Build lowlighter/metrics:${{ github.head_ref || 'master' }}
run: docker build -t lowlighter/metrics:$(echo ${{ github.head_ref || 'master' }} | sed 's/\//-/g') . run: docker build -t lowlighter/metrics:$(echo ${{ github.head_ref || 'master' }} | sed 's/\//-/g') .
- name: Run tests - name: Run tests
run: docker run --entrypoint="" lowlighter/metrics:$(echo ${{ github.head_ref || 'master' }} | sed 's/\//-/g') npm test -- metrics.test.js run: docker run --entrypoint="" lowlighter/metrics:$(echo ${{ github.head_ref || 'master' }} | sed 's/\//-/g') npm test-metrics
# Run CodeQL on branch # Run CodeQL on branch
analyze: analyze:

View File

@@ -5,8 +5,10 @@
"main": "index.mjs", "main": "index.mjs",
"scripts": { "scripts": {
"start": "node source/app/web/index.mjs", "start": "node source/app/web/index.mjs",
"test": "jest --runInBand --testPathIgnorePatterns presets.test.js", "test": "jest --runInBand",
"test-presets": "jest --runInBand presets.test.js", "test-contrib": "jest --runInBand ci.test.js --noStackTrace",
"test-presets": "jest --runInBand presets.test.js --noStackTrace",
"test-metrics": "jest --runInBand metrics.test.js",
"build": "node .github/scripts/build.mjs", "build": "node .github/scripts/build.mjs",
"presets": "node .github/scripts/presets_examples.mjs", "presets": "node .github/scripts/presets_examples.mjs",
"quickstart": "node .github/scripts/quickstart/index.mjs", "quickstart": "node .github/scripts/quickstart/index.mjs",