-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.test.yml
More file actions
56 lines (56 loc) · 1.54 KB
/
Copy pathdocker-compose.test.yml
File metadata and controls
56 lines (56 loc) · 1.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
services:
db_test:
image: postgres:16
environment:
POSTGRES_USER: test
POSTGRES_PASSWORD: test
POSTGRES_DB: app_test
healthcheck:
test: ["CMD-SHELL", "pg_isready -U test -d app_test"]
interval: 5s
timeout: 3s
retries: 10
backend_test:
container_name: backend_test
build:
context: ./backend
dockerfile: Dockerfile.test
environment:
PYTHONPATH: /app
PYTHONUNBUFFERED: "1"
DB_HOST: db_test
DB_PORT: "5432"
DB_USER: test
DB_PASS: test
DB_NAME: app_test
EMBEDDING_MODEL: ${EMBEDDING_MODEL}
OLLAMA_CHAT_MODEL: ${OLLAMA_CHAT_MODEL}
OLLAMA_BASE_URL: http://ollama:11434
depends_on:
db_test:
condition: service_healthy
volumes:
- ./backend/app:/app
- ./backend/tests:/tests
- ./backend/reports:/reports
command: ["pytest", "-q"]
frontend_test:
container_name: frontend_test
build:
context: ./frontend
dockerfile: Dockerfile.test
working_dir: /app
environment:
CI: "1"
EXPO_TUNNEL: ${EXPO_TUNNEL}
EXPO_DEVTOOLS_LISTEN_ADDRESS: ${EXPO_DEVTOOLS_LISTEN_ADDRESS}
REACT_NATIVE_PACKAGER_HOSTNAME: 192.168.1.3
EXPO_PUBLIC_API_HOST: ${EXPO_PUBLIC_API_HOST}
EXPO_PUBLIC_API_PORT: ${EXPO_PUBLIC_API_PORT}
EXPO_PUBLIC_API_BASE: ${EXPO_PUBLIC_API_BASE}
volumes:
- ./frontend/app:/app
- /app/node_modules
- ./reports/frontend:/reports/frontend
command: >-
sh -lc "npm ci && npm test -- --ci --runInBand --verbose"