2019-08-27 20:05:31 +00:00
|
|
|
name: CI
|
|
|
|
|
|
|
|
on: [push]
|
|
|
|
|
|
|
|
jobs:
|
2020-02-20 04:14:16 +00:00
|
|
|
build-and-test:
|
2019-08-27 20:05:31 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
2024-03-01 05:24:55 +00:00
|
|
|
node-version: [20.x]
|
2019-08-27 20:05:31 +00:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v1
|
|
|
|
- name: Use Node.js ${{ matrix.node-version }}
|
|
|
|
uses: actions/setup-node@v1
|
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node-version }}
|
2020-02-20 04:14:16 +00:00
|
|
|
- name: Install Dependencies
|
|
|
|
run: yarn
|
|
|
|
- name: Build
|
|
|
|
run: |
|
2020-12-10 06:47:50 +00:00
|
|
|
yarn workspace ani-cursor build
|
2020-05-18 05:12:17 +00:00
|
|
|
yarn workspace webamp build
|
|
|
|
yarn workspace webamp build-library
|
2020-12-22 20:30:19 +00:00
|
|
|
- name: Lint
|
|
|
|
run: |
|
2022-03-07 07:07:33 +00:00
|
|
|
yarn lint
|
2020-12-22 20:30:19 +00:00
|
|
|
yarn workspace webamp type-check
|
2020-02-20 04:14:16 +00:00
|
|
|
- name: Run Unit Tests
|
2020-12-10 06:47:50 +00:00
|
|
|
run: |
|
2022-03-07 07:25:50 +00:00
|
|
|
touch packages/skin-database/config.js
|
2022-03-07 06:37:37 +00:00
|
|
|
yarn test
|
2020-12-10 06:47:50 +00:00
|
|
|
yarn workspace webamp test
|
2020-02-20 04:14:16 +00:00
|
|
|
- name: Run Integration Tests
|
2020-05-18 05:12:17 +00:00
|
|
|
run: yarn workspace webamp integration-tests
|
2019-08-27 20:05:31 +00:00
|
|
|
env:
|
|
|
|
CI: true
|
2020-02-20 04:14:16 +00:00
|
|
|
- name: Upload Screenshot Diffs
|
|
|
|
if: failure()
|
2021-08-17 05:48:35 +00:00
|
|
|
uses: actions/upload-artifact@v2
|
2020-02-20 04:14:16 +00:00
|
|
|
with:
|
|
|
|
name: image_diffs
|
2020-05-18 05:12:17 +00:00
|
|
|
path: packages/webamp/js/__tests__/__image_snapshots__/__diff_output__/
|
2020-02-20 04:14:16 +00:00
|
|
|
- name: Generate New Screenshots
|
|
|
|
if: failure()
|
|
|
|
run: |
|
2020-05-18 05:12:17 +00:00
|
|
|
yarn workspace webamp integration-tests -u
|
2020-02-20 04:14:16 +00:00
|
|
|
- name: Upload New Screenshots
|
|
|
|
if: failure()
|
|
|
|
uses: actions/upload-artifact@v1
|
|
|
|
with:
|
|
|
|
name: new_images
|
2020-05-18 05:12:17 +00:00
|
|
|
path: packages/webamp/js/__tests__/__image_snapshots__/
|