1
0
mirror of https://github.com/kremalicious/blog.git synced 2025-01-03 18:35:07 +01:00
blog/.github/workflows/test.yml

41 lines
865 B
YAML
Raw Normal View History

2019-11-17 02:32:16 +01:00
name: Test
on: [push]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
2019-11-17 12:24:08 +01:00
2019-11-17 02:32:16 +01:00
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: '12.x'
- name: Cache node modules
uses: actions/cache@v1
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: ${{ runner.os }}-node-
- name: Cache Gatsby build output
uses: actions/cache@v1
with:
path: public
key: ${{ runner.os }}-public
- name: Install Dependencies
run: npm ci
- name: Test
run: npm test
- name: Build
run: npm run build
env:
CI: true
2019-11-17 13:11:42 +01:00
GATSBY_GITHUB_TOKEN: ${{ secrets.GATSBY_GITHUB_TOKEN }}