Skip to content

add postgre sql testing #94

add postgre sql testing

add postgre sql testing #94

Workflow file for this run

name: CI
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install modules
run: npm install
- name: Build
run: npm run build
- name: Run sync-database-models command
id: sync
run: npm exec sync-database-models
- name: Run tests
run: npm test
test_postgre:
runs-on: ubuntu-latest
needs: build
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: 123456
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v2
- name: Install modules
run: npm install
- name: Run tests
env:
POSTGRES_HOST: postgres
POSTGRES_DB: postgres
POSTGRES_USER: postgres
POSTGRES_PASSWORD: 123456
POSTGRES_PORT: 5432
run: npm run test:connection