This commit is contained in:
sbriat 2023-02-08 16:59:14 +01:00
parent 53e16754f7
commit 11de02b2bf
4 changed files with 23 additions and 20 deletions

View File

@ -16,10 +16,10 @@ test:
services:
- docker:dind
script:
- docker-compose -f docker-compose.ci.yml --env-file ci/.env.ci up -d
- docker-compose -f docker-compose.ci-1.yml --env-file ci/.env.ci up -d
- sh ci/wait-up.sh
- sleep 30
- docker-compose -f docker-compose.ci.yml --env-file ci/.env.ci logs
- docker-compose -f docker-compose.ci-1.yml --env-file ci/.env.ci logs
- docker-compose -f docker-compose.ci-2.yml --env-file ci/.env.ci up -d
- docker exec -t v3-territory sh -c "npm run test:integration:ci"
coverage: /All files[^|]*\|[^|]*\s+([\d\.]+)/
rules:

View File

@ -1,6 +1,6 @@
#!/bin/bash
testlog() {
docker logs v3-territory-db-test | grep -q "database system is ready to accept connections"
docker logs v3-territory-db-test | grep -q "listening on IPv6 address "::", port 5432"
}
testlog 2> /dev/null

View File

@ -1,22 +1,6 @@
version: '3.8'
services:
api:
container_name: v3-territory
build:
dockerfile: ci/Dockerfile
context: .
env_file:
- ci/.env.ci
ports:
- 5004:5004
depends_on:
- db
- broker
- redis
networks:
- v3-network
redis:
container_name: v3-territory-redis
image: ${REDIS_IMAGE}

19
docker-compose.ci-2.yml Normal file
View File

@ -0,0 +1,19 @@
version: '3.8'
services:
api:
container_name: v3-territory
build:
dockerfile: ci/Dockerfile
context: .
env_file:
- ci/.env.ci
ports:
- 5004:5004
networks:
- v3-network
networks:
v3-network:
name: v3-network
external: true