feat: implement e2e test for CompanyResolver (#944)

* feat: wip e2e server test

* feat: use github action postgres & use infra for local

* feat: company e2e test

* feat: add company e2e test for permissions

* Simplify server e2e test run

* Fix lint

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
This commit is contained in:
Jérémy M
2023-07-27 18:48:40 +02:00
committed by GitHub
parent 9027406fdf
commit 157e5b9a2e
25 changed files with 655 additions and 59 deletions

View File

@ -5,7 +5,26 @@ on:
- main
pull_request_target:
jobs:
postgres-job:
runs-on: ubuntu-latest
container: node:10.18-jessie
steps:
- run: echo "Postgres job finished"
services:
postgres:
image: postgres
env:
POSTGRES_HOST: postgres
POSTGRES_PASSWORD: postgrespassword
POSTGRES_DB: test
POSTGRES_PORT: 5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
server-test:
needs: postgres-job
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
@ -27,3 +46,6 @@ jobs:
- name: Server / Run jest tests
run: |
cd server && yarn test
- name: Server / Run e2e tests
run: |
cd server && yarn test:e2e