fix: icon for aft (#44) #125
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: CI-CD | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master, development ] | |
workflow_dispatch: | |
jobs: | |
build_test: | |
runs-on: ubuntu-latest | |
services: | |
postgres: | |
image: postgres | |
env: | |
POSTGRES_USERNAME: postgres | |
POSTGRES_PASSWORD: postgres | |
POSTGRES_DB: test-db | |
ports: | |
- 5432:5432 | |
strategy: | |
matrix: | |
node-version: [16.x, 18.x] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: setup node | |
uses: actions/setup-node@master | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install dependencies | |
run: | | |
npm install | |
npm ci | |
- name: Connect to PostgreSQL and run migrations | |
run: | | |
npm install -g sequelize-cli | |
npm run db:migrate | |
npm run db:seed:all | |
env: | |
NODE_ENV: test | |
POSTGRES_USERNAME: postgres | |
POSTGRES_PASSWORD: postgres | |
POSTGRES_TEST_HOST: localhost | |
POSTGRES_PORT: 5432 | |
- name: Run linter and tests | |
run: | | |
npm run lint | |
npm run test | |
env: | |
NODE_ENV: test | |
TOKEN_KEY: test | |
POSTGRES_USERNAME: postgres | |
POSTGRES_PASSWORD: postgres | |
POSTGRES_TEST_HOST: localhost | |
POSTGRES_PORT: 5432 | |
EVENTS_SERVICE_URL: fake.url |