add gh action for quality gate
This commit is contained in:
@@ -0,0 +1,63 @@
|
|||||||
|
name: PR Quality Gate (client applications)
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
paths:
|
||||||
|
- "js/mobile/**"
|
||||||
|
- "js/desktop/**"
|
||||||
|
branches: [ main ]
|
||||||
|
types: [ opened, synchronize, reopened ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
mobile:
|
||||||
|
name: Lint & format check
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
working-directory: js/mobile
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Check out repository code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Set up Node.js runtime
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-node-version: '20'
|
||||||
|
cache: 'yarn'
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: yarn install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Run Code Linter
|
||||||
|
run: yarn lint
|
||||||
|
|
||||||
|
- name: Run Unit Tests
|
||||||
|
run: yarn format:check
|
||||||
|
desktop:
|
||||||
|
name: Lint & format check
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
working-directory: js/desktop
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Check out repository code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Set up Node.js runtime
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-node-version: '20'
|
||||||
|
cache: 'yarn'
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: yarn install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Run Code Linter
|
||||||
|
run: yarn lint
|
||||||
|
|
||||||
|
- name: Run Unit Tests
|
||||||
|
run: yarn format:check
|
||||||
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user