mirror of
https://github.com/holidayapi/holidayapi-node.git
synced 2025-06-21 12:36:33 +00:00
* Updated supported Node.js versions Dropped support for 14 and 16 in favor of the current LTS versions 18 and 20. * Updated Node.js dependencies Bumped nearly all dependencies to the latest. The exception being `node-fetch` which made the jump to using ESM which is still causing folks a lot of grief. * Shored code coverage back up to 100% Had some remnants from when this library did sanity checks pre-flight to the API that required additional tests to cover them, or just adjusting the argument defaults. * Removed the "build" badge from the README Seems there were some gotchas with that badge that makes it kind of a pain, as it has to be hard coded a certain way. I messed with it and couldn't get it working, seems like more trouble than it's worth. Further details: https://github.com/badges/shields/issues/8671 * Added .nvmrc file Pretty self explanatory. * Bumped version number Lucky number 7, y'all!
31 lines
799 B
YAML
31 lines
799 B
YAML
name: Test
|
|
on: [push, pull_request]
|
|
jobs:
|
|
test:
|
|
name: Test Node.js ${{ matrix.node-version }}
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
node-version: ['18', '20']
|
|
steps:
|
|
- name: Checkout Code
|
|
uses: actions/checkout@v2
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v1
|
|
with:
|
|
node-version: ${{ matrix.node-version }}
|
|
- name: Node.js Version
|
|
run: node --version
|
|
- name: NPM Version
|
|
run: npm --version
|
|
- name: Install Dependencies
|
|
run: npm install
|
|
- name: Run Linter
|
|
run: npm run lint
|
|
- name: Run Tests
|
|
run: npm run test:coverage
|
|
- name: Upload Coverage
|
|
if: ${{ matrix.node-version == '20' }}
|
|
uses: codecov/codecov-action@v1
|
|
with:
|
|
file: ./coverage/lcov.info
|