1
0
Fork 1
mirror of https://example.com synced 2024-11-24 01:26:39 +09:00
firefish/.github/workflows/nodejs.yml
MeiMei 03b04acb16
テスト用コンテナの調整 (#7838)
* Tune test container

* docs

* fix cp config

* doc

* a
2021-10-16 17:12:20 +09:00

59 lines
1.2 KiB
YAML

name: Node.js CI
on:
push:
branches:
- master
- develop
pull_request:
jobs:
build_and_test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x, 16.x]
services:
postgres:
image: postgres:12.2-alpine
ports:
- 54312:5432
env:
POSTGRES_DB: test-misskey
POSTGRES_HOST_AUTH_METHOD: trust
redis:
image: redis:4.0-alpine
ports:
- 56312:6379
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: yarn install
- name: Check yarn.lock
run: git diff --exit-code yarn.lock
- name: Copy Configure
run: cp test/test.yml .config
- name: Build
run: yarn build
- name: Test
run: yarn test
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- uses: actions/setup-node@v1
with:
node-version: 12.x
- run: yarn install
- run: yarn lint