mirror of
https://github.com/TheAlgorithms/JavaScript.git
synced 2025-12-19 06:58:15 +08:00
relates to #586 and #720 Added npm scripts for doctest and style checking via standard. This allows us to call those directly via npm and not via npx. The CI job itself is now split into distinct steps (makes it more visible which step failed).
30 lines
524 B
YAML
30 lines
524 B
YAML
name: Continuous Integration
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: '14'
|
|
|
|
- name: 📦 Install dependencies
|
|
run: npm ci
|
|
env:
|
|
CI: true
|
|
|
|
- name: 🧪 Run tests
|
|
run: |
|
|
npm run doctest || true # TODO: Add all doctests
|
|
npm test
|
|
env:
|
|
CI: true
|
|
|
|
- name: 💄 Code style
|
|
run: npm run style
|
|
env:
|
|
CI: true
|