feat: add distance value object and ci workflows
This commit is contained in:
@@ -0,0 +1,65 @@
|
||||
name: Backend Quality
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- "server/**"
|
||||
- ".github/workflows/backend-quality.yml"
|
||||
pull_request:
|
||||
paths:
|
||||
- "server/**"
|
||||
- ".github/workflows/backend-quality.yml"
|
||||
|
||||
jobs:
|
||||
static-analysis:
|
||||
name: PHPStan
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: server
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: "8.2"
|
||||
coverage: none
|
||||
tools: composer
|
||||
extensions: mbstring
|
||||
ini-values: memory_limit=-1
|
||||
cache: composer
|
||||
|
||||
- name: Install dependencies
|
||||
run: composer install --no-interaction --prefer-dist
|
||||
|
||||
- name: Run PHPStan
|
||||
run: vendor/bin/phpstan analyse --memory-limit=1G
|
||||
|
||||
coding-standards:
|
||||
name: ECS
|
||||
runs-on: ubuntu-latest
|
||||
needs: static-analysis
|
||||
defaults:
|
||||
run:
|
||||
working-directory: server
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: "8.2"
|
||||
coverage: none
|
||||
tools: composer
|
||||
extensions: mbstring
|
||||
ini-values: memory_limit=-1
|
||||
cache: composer
|
||||
|
||||
- name: Install dependencies
|
||||
run: composer install --no-interaction --prefer-dist
|
||||
|
||||
- name: Check coding standards
|
||||
run: vendor/bin/ecs check
|
||||
@@ -0,0 +1,40 @@
|
||||
name: Backend Tests
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- "server/**"
|
||||
- ".github/workflows/backend-tests.yml"
|
||||
pull_request:
|
||||
paths:
|
||||
- "server/**"
|
||||
- ".github/workflows/backend-tests.yml"
|
||||
|
||||
jobs:
|
||||
phpunit:
|
||||
name: PHPUnit
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
defaults:
|
||||
run:
|
||||
working-directory: server
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: "8.2"
|
||||
coverage: none
|
||||
tools: composer
|
||||
extensions: mbstring
|
||||
ini-values: memory_limit=-1
|
||||
cache: composer
|
||||
|
||||
- name: Install dependencies
|
||||
run: composer install --no-interaction --prefer-dist
|
||||
|
||||
- name: Run PHPUnit
|
||||
run: vendor/bin/phpunit
|
||||
@@ -0,0 +1,81 @@
|
||||
name: Frontend Quality
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- "client/**"
|
||||
- ".github/workflows/frontend-quality.yml"
|
||||
pull_request:
|
||||
paths:
|
||||
- "client/**"
|
||||
- ".github/workflows/frontend-quality.yml"
|
||||
|
||||
jobs:
|
||||
eslint:
|
||||
name: ESLint
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: client
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: "20"
|
||||
cache: "npm"
|
||||
cache-dependency-path: client/package-lock.json
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Run ESLint
|
||||
run: npm run lint
|
||||
|
||||
prettier:
|
||||
name: Prettier
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: client
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: "20"
|
||||
cache: "npm"
|
||||
cache-dependency-path: client/package-lock.json
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Check formatting
|
||||
run: npx prettier --check .
|
||||
|
||||
typecheck:
|
||||
name: Type Check
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: client
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: "20"
|
||||
cache: "npm"
|
||||
cache-dependency-path: client/package-lock.json
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Run TypeScript type check
|
||||
run: npm run typecheck
|
||||
Reference in New Issue
Block a user