Skip to content

add ./test to .npmignore #20

add ./test to .npmignore

add ./test to .npmignore #20

Workflow file for this run

name: CI
on: [ push ]
env:
CI: true
jobs:
lint:
uses: haraka/.github/.github/workflows/lint.yml@master
coverage:
uses: haraka/.github/.github/workflows/coverage.yml@master
secrets: inherit
test:
needs: [ lint, get-lts ]
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest ]
node-version: ${{ fromJson(needs.get-lts.outputs.active) }}
fail-fast: false
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
name: Node ${{ matrix.node-version }} on ${{ matrix.os }}
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm test
test-win-latest:
needs: [ lint, get-lts ]
# no docker/images support on Windows (currently), so run w/o Redis
# also, stack run commands so test doesn't begin before install completes
runs-on: windows-latest
strategy:
matrix:
node-version: ${{ fromJson(needs.get-lts.outputs.active) }}
fail-fast: false
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
name: Node.js ${{ matrix.node-version }} on ${{ matrix.os }}
with:
node-version: ${{ matrix.node-version }}
# Needed for Node 14 on Windows 2022 (which uses Visual Studio 2022)
# The default node-gyp installed with Node 14 doesn't recognize VS 2022
# Remove this when Node 14 support is dropped (2023-04-30)
- name: Update npm
if: matrix.node-version == 14
run: npm install -g npm
# To address a node-gyp install issues in Windows starting in Node 16
# This should be temporary and hopefully should be removed in the future
- name: Install node-gyp (temp workaround)
run: npx node-gyp@^9.0.0 install
- run: npm install
- run: npm run test
test-win-2019:
needs: [ test-win-latest, get-lts ]
runs-on: windows-2019
strategy:
matrix:
node-version: ${{ fromJson(needs.get-lts.outputs.active) }}
fail-fast: false
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
name: Node.js ${{ matrix.node-version }} on ${{ matrix.os }}
with:
node-version: ${{ matrix.node-version }}
- name: Update npm
if: matrix.node-version == 14
run: npm install -g npm
- name: Install node-gyp (temp workaround)
run: npx node-gyp@^9.0.0 install
- run: npm install
- run: npm run test
get-lts:
runs-on: ubuntu-latest
steps:
- id: get
uses: msimerson/node-lts-versions@v1
outputs:
active: ${{ steps.get.outputs.active }}
lts: ${{ steps.get.outputs.lts }}