Skip to content

fix: Use massongit/actions-get-node-active-major-versions in CI test #426

fix: Use massongit/actions-get-node-active-major-versions in CI test

fix: Use massongit/actions-get-node-active-major-versions in CI test #426

Workflow file for this run

name: test
on: [ push, pull_request ]
env:
CI: true
permissions:
contents: read
jobs:
get-node-active-major-versions:
runs-on: ubuntu-latest
outputs:
versions: ${{steps.get_versions.outputs.versions}}
steps:
- name: Get versions
id: get_versions
uses: massongit/actions-get-node-active-major-versions@v1
test:
name: "Test on Node.js ${{ matrix.node-version }} x ${{ matrix.os }}"
runs-on: ${{ matrix.os }}
needs: get-node-active-major-versions
strategy:
matrix:
node-version: ${{fromJson(needs.get-node-active-major-versions.outputs.versions)}}
os: [ ubuntu-latest, windows-latest ]
steps:
- name: checkout
uses: actions/checkout@v4
- name: setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
cache: "yarn"
node-version: ${{ matrix.node-version }}
- name: Install
run: yarn install
- name: Test
run: yarn test