Skip to content

Fixing the version response and a bug in the dedupe logic #484

Fixing the version response and a bug in the dedupe logic

Fixing the version response and a bug in the dedupe logic #484

Workflow file for this run

on:
push:
branches: [main]
pull_request:
# The branches below must be a subset of the branches above
branches: [main]
name: Test Node
jobs:
test:
name: Test on node ${{ matrix.node-version }} and ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version: [18.x, 20.x]
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: ~/.npm
key: ${{ matrix.os }}-node-${{ matrix.node-version }}-npm-${{ hashFiles('package-lock.json') }}
restore-keys: ${{ matrix.os }}-node-${{ matrix.node-version }}-npm-
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Install deps
run: npm ci --omit=dev
- name: build
run: npm run build --if-present
- name: lint
run: npm run lint
- name: test
run: npm test
- name: Check Test File Exists
if: success() || failure()
id: hasTests
run: |
if compgen -G "TestResults/*" > /dev/null; then
hasTest=true
else
hasTest=false
fi
echo "hasTests=$hasTest" >> $GITHUB_OUTPUT
- name: Test Reporter
id: test-report
if: ${{ steps.hasTests.outputs.hasTests == 'true' }}
uses: phoenix-actions/test-reporting@v12
with:
name: ${{ github.event.repository.full_name }} Test Results
path: TestResults/test.xml
reporter: jest-junit
output-to: step-summary