2023-03-07 11:23:44 +00:00
|
|
|
name: Test (frontend)
|
2021-10-27 16:16:13 +00:00
|
|
|
|
2020-03-19 17:46:13 +00:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
2024-03-20 12:15:37 +00:00
|
|
|
- beta
|
2024-01-09 18:10:45 +00:00
|
|
|
- io
|
2024-03-20 12:15:37 +00:00
|
|
|
- host
|
2024-01-08 14:51:31 +00:00
|
|
|
paths:
|
|
|
|
- packages/frontend/**
|
|
|
|
# for permissions
|
|
|
|
- packages/misskey-js/**
|
|
|
|
# for e2e
|
|
|
|
- packages/backend/**
|
|
|
|
|
2020-03-19 17:46:13 +00:00
|
|
|
pull_request:
|
2024-01-08 14:51:31 +00:00
|
|
|
paths:
|
|
|
|
- packages/frontend/**
|
|
|
|
# for permissions
|
|
|
|
- packages/misskey-js/**
|
|
|
|
# for e2e
|
|
|
|
- packages/backend/**
|
2020-01-09 05:35:04 +00:00
|
|
|
|
|
|
|
jobs:
|
2023-03-09 03:48:39 +00:00
|
|
|
vitest:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
2024-11-22 16:44:01 +00:00
|
|
|
node-version: [22.x]
|
2023-03-09 03:48:39 +00:00
|
|
|
|
|
|
|
steps:
|
2024-12-24 16:36:30 +00:00
|
|
|
- uses: actions/checkout@v4
|
2023-03-09 03:48:39 +00:00
|
|
|
with:
|
2024-05-08 15:33:39 +00:00
|
|
|
fetch-depth: 0
|
2023-03-09 03:48:39 +00:00
|
|
|
submodules: true
|
|
|
|
- name: Install pnpm
|
2025-01-16 19:32:16 +00:00
|
|
|
uses: pnpm/action-setup@v4.0.0
|
2023-03-09 03:48:39 +00:00
|
|
|
with:
|
|
|
|
run_install: false
|
|
|
|
- name: Use Node.js ${{ matrix.node-version }}
|
2024-10-25 07:00:23 +00:00
|
|
|
uses: actions/setup-node@v4.1.0
|
2023-03-09 03:48:39 +00:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node-version }}
|
|
|
|
cache: 'pnpm'
|
|
|
|
- run: pnpm i --frozen-lockfile
|
|
|
|
- name: Check pnpm-lock.yaml
|
|
|
|
run: git diff --exit-code pnpm-lock.yaml
|
|
|
|
- name: Copy Configure
|
2025-01-16 19:51:12 +00:00
|
|
|
run: cp .forgejo/misskey/test-forgejo.yml .config/test.yml
|
2023-03-09 03:48:39 +00:00
|
|
|
- name: Build
|
|
|
|
run: pnpm build
|
|
|
|
- name: Test
|
2025-01-12 03:27:55 +00:00
|
|
|
run: pnpm --filter frontend test
|