[chore] Fix up #94
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Testing | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
static-checks: | |
name: Static Checks | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [20.x] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install dependencies | |
run: npm ci | |
- name: Build | |
run: npm run build --if-present | |
- name: ESLint | |
run: npm run eslint | |
- name: Type Coverage | |
run: npm run type-coverage | |
- name: Unused Dependencies | |
run: npm run depcheck | |
unit-tests: | |
name: Unit Tests | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [20.x] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Setup DynamoDB Local | |
uses: rrainn/[email protected] | |
with: | |
sharedDb: true | |
port: 8000 | |
cors: '*' | |
- name: Install dependencies | |
run: npm ci | |
- name: Build | |
run: npm run build --if-present | |
- name: Database Migration | |
run: npm run db:migrate -- --param="telegramBotToken=fake-value" --param="telegramBotWebhookUrl=fake-value" --param="vkToken=fake-value" --param="vkConfirmation=fake-value" | |
- name: Run Unit-Tests | |
run: npm run test:ci |