actions-hugo/.github/workflows/test.yml

63 lines
1.1 KiB
YAML
Raw Normal View History

2019-09-16 01:27:57 +02:00
name: 'Test'
on:
pull_request:
2019-09-23 04:33:57 +02:00
types: [opened, synchronize]
push:
2019-10-01 13:10:45 +02:00
branches:
- master
2019-09-16 01:27:57 +02:00
jobs:
test:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
with:
fetch-depth: 1
2019-09-16 01:27:57 +02:00
- name: Install dependencies
run: npm ci
- name: Format check
run: npm run format:check
2019-09-16 01:27:57 +02:00
- name: Lint
run: npm run lint
- name: Test
run: npm test
- uses: actions/upload-artifact@master
with:
name: coverage
path: coverage
2019-09-16 01:27:57 +02:00
test-prod:
runs-on: ${{ matrix.os }}
needs: test
2019-09-16 01:27:57 +02:00
strategy:
matrix:
os: ['ubuntu-18.04', 'macOS-10.14', 'windows-2019']
hugo-version: ['latest', '0.57.2']
extended: [true, false]
# exclude:
# - os: 'macOS-10.14'
# hugo-version: 'latest'
# extended: false
# - os: 'windows-2019'
# hugo-version: 'latest'
# extended: false
2019-09-16 01:27:57 +02:00
steps:
- uses: actions/checkout@v1
with:
fetch-depth: 1
2019-09-16 01:27:57 +02:00
- name: Test action
uses: ./
with:
hugo-version: ${{ matrix.hugo-version }}
extended: ${{ matrix.extended }}