chore(ci): add GitHub action for showcase testing (#6002)

This commit is contained in:
Joshua Chen 2021-11-24 18:25:49 +08:00 committed by GitHub
parent b31044dc8a
commit 057e3f34da
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

26
.github/workflows/showcase-test.yml vendored Normal file
View file

@ -0,0 +1,26 @@
name: Showcase Tests
on:
pull_request:
branches:
- main
paths:
- website/src/data/**
jobs:
validate-config:
name: Validate Showcase Config
timeout-minutes: 30
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
cache: yarn
- name: Installation
run: yarn
- name: Test
run: yarn test website/src/data/__tests__/user.test.ts
# TODO another job to optimize the images, see https://github.com/facebook/docusaurus/issues/5980