Merge pull request #86 from keenwon/dependabot/npm_and_yarn/postcss-8… #734
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: unittest | |
on: push | |
jobs: | |
test: | |
name: Test on node ${{ matrix.node_version }} and ${{ matrix.os }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
node_version: [16, 18, 20, 22] | |
os: [ubuntu-latest, windows-latest, macOS-latest] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Use Node.js ${{ matrix.node_version }} | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node_version }} | |
architecture: 'x64' | |
- name: Upgrade Npm | |
run: npm install npm@6 | |
if: matrix.node_version == 8 && matrix.os == 'windows-latest' | |
- name: npm install | |
run: npm install | |
- name: npm run test | |
run: npm run test | |
- name: npm run test:coverage | |
if: matrix.node_version == 14 && matrix.os == 'ubuntu-latest' | |
run: npm run test:coverage | |
- name: Upload coverage to Codecov | |
if: matrix.node_version == 14 && matrix.os == 'ubuntu-latest' | |
uses: codecov/codecov-action@v2 | |
with: | |
token: ${{secrets.CODECOV_TOKEN}} | |
file: ./coverage/lcov.info |