# Docker Compose configuration for AIDB testing
# This file is AUTO-GENERATED by ComposeGeneratorService
# DO NOT EDIT MANUALLY - changes will be overwritten
#
# To modify:
# - Static services: Edit docker-compose.base.yaml
# - Language configs: Edit languages.yaml
# - Service templates: Edit templates/*.j2
#
# Generation is automatic when running './dev-cli test run'
# Docker Compose Base Configuration for AIDB Testing
# This file contains static services that don't vary by language.
# Language-specific services are generated from templates.
#
# DO NOT EDIT THIS FILE MANUALLY - it's part of the compose generation system.
# Language-specific services are defined in languages.yaml and generated automatically.
#
# Usage:
# docker compose -f docker-compose.yaml --profile mcp up
#
# Available profiles:
# - base: Core test runner (always included)
# - mcp: MCP integration testing
# - adapters: Adapter testing and building
# - matrix: Multi-version matrix testing
# Project name for consistent container naming
name: aidb-tests
# Reusable build configuration
# Note: Version defaults should match versions.json
x-build-args: &build-args
RUNTIME_TAG: ${RUNTIME_TAG:-latest}
AIDB_TEST_BASE_IMAGE: ${AIDB_TEST_BASE_IMAGE:-aidb-test-base:latest}
# Infrastructure versions
PYTHON_VERSION: ${PYTHON_VERSION:-3.12}
PYTHON_BASE_TAG: ${PYTHON_BASE_TAG:-3.12-slim}
NODE_VERSION: ${NODE_VERSION:-22}
JAVA_VERSION: ${JAVA_VERSION:-21}
# Adapter versions
DEBUGPY_VERSION: ${DEBUGPY_VERSION:-1.8.16}
JDTLS_VERSION: ${JDTLS_VERSION:-1.55.0-202511271007}
# Global package versions
PIP_VERSION: ${PIP_VERSION:-25.3}
SETUPTOOLS_VERSION: ${SETUPTOOLS_VERSION:-80.9.0}
WHEEL_VERSION: ${WHEEL_VERSION:-0.45.1}
TYPESCRIPT_VERSION: ${TYPESCRIPT_VERSION:-5.9.3}
TS_NODE_VERSION: ${TS_NODE_VERSION:-10.9.2}
# Reusable volume configuration (legacy - for services not using container-specific cache)
x-common-volumes: &common-volumes
# Mount entire repo for full access
- ${REPO_ROOT:-.}:/workspace:rw
# Test cache for faster reruns
- test-cache:/root/.cache
# Pre-built adapters from repo cache (install via './dev-cli adapters install-all' or build via './dev-cli adapters build')
# Primary mount - tests can delete/modify these
- ${REPO_ROOT:-.}/.cache/adapters:/root/.aidb/adapters:rw
# Backup mount - pristine copy for test restoration
- ${REPO_ROOT:-.}/.cache/adapters:/tmp/.aidb/adapters:ro
# Docker socket for Docker-in-Docker tests
- /var/run/docker.sock:/var/run/docker.sock:ro
# Reusable individual volume mounts (for DRY composition)
x-workspace-mount: &workspace-mount
${REPO_ROOT:-.}:/workspace:rw
x-test-cache-mount: &test-cache-mount
test-cache:/root/.cache
x-adapters-mount-rw: &adapters-mount-rw
${REPO_ROOT:-.}/.cache/adapters:/root/.aidb/adapters:rw
x-adapters-mount-ro: &adapters-mount-ro
${REPO_ROOT:-.}/.cache/adapters:/tmp/.aidb/adapters:ro
x-docker-socket-mount: &docker-socket-mount
/var/run/docker.sock:/var/run/docker.sock:ro
# Reusable label configuration
x-aidb-labels: &aidb-labels
com.aidb.project: "aidb"
com.aidb.managed: "true"
com.aidb.environment: "test"
x-test-labels: &test-labels
<<: *aidb-labels
com.aidb.component: "test"
x-mcp-labels: &mcp-labels
<<: *aidb-labels
com.aidb.component: "mcp"
x-adapter-labels: &adapter-labels
<<: *aidb-labels
com.aidb.component: "adapter"
x-utility-labels: &utility-labels
<<: *aidb-labels
com.aidb.component: "utility"
# Reusable environment configuration
x-base-environment: &base-environment
# Core test configuration
AIDB_DOCKER_TEST_MODE: "1"
AIDB_LOG_LEVEL: ${AIDB_LOG_LEVEL:-DEBUG}
AIDB_ADAPTER_TRACE: ${AIDB_ADAPTER_TRACE:-0}
# Always import local sources from the bind mount first so code changes are picked up
PYTHONPATH: /workspace/src:/workspace
# Performance tuning for tests
AIDB_SKIP_POST_STOP_ORPHAN_CLEANUP: "1"
AIDB_DISCONNECT_TIMEOUT_S: "0.5"
# Test selection
TEST_LANGUAGE: ${TEST_LANGUAGE:-all}
TEST_SUITE: ${TEST_SUITE:-}
TEST_PATTERN: ${TEST_PATTERN:-}
TEST_MARKERS: ${TEST_MARKERS:-}
TEST_PATH: ${TEST_PATH:-}
# Performance tuning
PYTEST_ADDOPTS: ${PYTEST_ADDOPTS:--v}
PYTEST_PARALLEL: ${PYTEST_PARALLEL:-auto}
PYTEST_TIMEOUT: ${PYTEST_TIMEOUT:-300}
# CI/CD detection
CI: ${CI:-false}
GITHUB_ACTIONS: ${GITHUB_ACTIONS:-}
# Adapter-specific environment
x-adapter-environment: &adapter-environment
<<: *base-environment
# JavaScript adapter
AIDB_JAVASCRIPT_PATH: /root/.aidb/adapters/javascript/src/dapDebugServer.js
NODE_PATH: /root/.aidb/adapters/javascript/node_modules
# Java adapter
AIDB_JAVA_PATH: /root/.aidb/adapters/java/java-debug.jar
JDT_LS_HOME: ${JDT_LS_HOME:-/opt/jdtls}
# Performance: Reduce post-disconnect delay for pooled bridges (default 1.5s)
AIDB_JAVA_POOLED_POST_DISCONNECT_DELAY: "0.5"
# Python adapter
AIDB_PYTHON_PATH: /root/.aidb/adapters/python/debugpy/__init__.py
services:
# ===========================
# BASE: Core Test Runner
# ===========================
test-runner:
profiles: ["base"]
build:
context: ${REPO_ROOT:-../../..}
dockerfile: src/tests/_docker/dockerfiles/Dockerfile.test.python
args: *build-args
image: aidb-test-python:${IMAGE_TAG:-latest}
container_name: aidb-test-runner
volumes:
- ${REPO_ROOT:-.}:/workspace:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-runner/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-runner/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
- test-cache:/root/.cache
- ${REPO_ROOT:-.}/.cache/adapters:/root/.aidb/adapters:rw
- ${REPO_ROOT:-.}/.cache/adapters:/tmp/.aidb/adapters:ro
- /var/run/docker.sock:/var/run/docker.sock:ro
environment: *base-environment
working_dir: /workspace
command: ${TEST_COMMAND:-bash}
networks:
- test-network
tmpfs:
- /tmp:exec
stdin_open: true
tty: true
labels: *test-labels
healthcheck:
test: ["CMD-SHELL", "python -c 'import pytest; import aidb; print(\"healthy\")' && test -d /root/.aidb/adapters"]
interval: 10s
timeout: 5s
start_period: 10s
retries: 3
# ===========================
# MCP: MCP Testing Services
# ===========================
mcp-test-runner:
profiles: ["mcp"]
extends: test-runner
container_name: aidb-mcp-test
volumes:
- *workspace-mount
# Session-scoped to isolate logs from different test runs
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-test/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-test/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
environment:
<<: *adapter-environment
TEST_SUITE: mcp
TEST_PROFILE: ${MCP_PROFILE:-comprehensive}
labels: *mcp-labels
healthcheck:
test:
[
"CMD-SHELL",
"test -f /root/.aidb/adapters/python/debugpy/__init__.py &&
test -f /root/.aidb/adapters/javascript/src/dapDebugServer.js &&
test -f /root/.aidb/adapters/java/java-debug.jar",
]
interval: 10s
timeout: 5s
start_period: 15s
retries: 3
command: |
bash -lc '
set -euo pipefail
echo "🧪 MCP Test Runner Started"
echo "Languages: ${TEST_LANGUAGE}"
cd /workspace
python -m pip install -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/aidb_mcp/} \
${TEST_PATTERN:+-k ${TEST_PATTERN}} \
${TEST_MARKERS:+-m ${TEST_MARKERS}} \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
# Shared integration tests (DebugInterface tests)
shared-test-runner:
profiles: ["shared"]
extends: test-runner
container_name: aidb-shared-test
labels: *test-labels
environment:
<<: *adapter-environment
TEST_SUITE: shared
volumes:
- ${REPO_ROOT:-.}:/workspace:rw
# Session-scoped to isolate logs from different test runs
- ${REPO_ROOT:-.}/.cache/container-data/aidb-shared-test/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-shared-test/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
command: |
bash -lc '
set -euo pipefail
echo "🧪 Shared Test Runner (DebugInterface Tests)"
cd /workspace
python -m pip install -e .[test,dev] -q
python -m pytest src/tests/aidb_shared/ \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v --tb=short 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
# Generated program E2E tests
generated-program-test-runner:
profiles: ["generated", "e2e"]
extends: test-runner
container_name: aidb-generated-program-test
labels: *test-labels
environment:
<<: *adapter-environment
TEST_SUITE: generated_programs
AIDB_DOCKER_TEST_MODE: "1" # Enable Docker path resolution
volumes:
- ${REPO_ROOT:-.}:/workspace:rw
# Session-scoped to isolate logs from different test runs
- ${REPO_ROOT:-.}/.cache/container-data/aidb-generated-program-test/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-generated-program-test/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
command: |
bash -lc '
set -euo pipefail
echo "🧪 Generated Program E2E Tests"
cd /workspace
python -m pip install -e .[test,dev] -q
python -m pytest src/tests/aidb_shared/e2e/test_generated_programs.py \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v --tb=short 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
# ===========================
# ADAPTERS: Adapter Testing
# ===========================
adapter-builder:
profiles: ["adapters"]
build:
context: ${REPO_ROOT:-../../..}
dockerfile: src/tests/_docker/dockerfiles/Dockerfile.test.python
args: *build-args
image: aidb-test-python:${IMAGE_TAG:-latest}
container_name: aidb-adapter-builder
volumes:
- ${REPO_ROOT:-../../../..}:/workspace:rw
- ${REPO_ROOT:-../../../..}/.cache/adapters:/root/.aidb/adapters:rw
- ${REPO_ROOT:-../../../..}/.cache/adapters:/tmp/.aidb/adapters:ro
environment:
<<: *adapter-environment
BUILD_ADAPTERS: ${BUILD_ADAPTERS:-javascript,java}
BUILD_PLATFORM: ${BUILD_PLATFORM:-linux}
BUILD_ARCH: ${BUILD_ARCH:-x64}
working_dir: /workspace
networks:
- test-network
labels: *adapter-labels
healthcheck:
test: ["CMD-SHELL", "python -c 'import sys; import json; print(\"healthy\")' && test -d /workspace"]
interval: 10s
timeout: 5s
start_period: 10s
retries: 3
command: >
bash -c "
echo '🔨 Adapter Builder Started'
echo 'Note: Adapters should be built locally with: ./dev-cli adapters build'
echo 'Checking adapter availability...'
ls -la /root/.aidb/adapters/ || echo 'No adapters found!'
echo 'To build adapters, run: ./dev-cli adapters build'
"
adapter-test-runner:
profiles: ["adapters"]
extends: test-runner
container_name: aidb-adapter-test
volumes:
- *workspace-mount
# Session-scoped to isolate logs from different test runs
- ${REPO_ROOT:-.}/.cache/container-data/aidb-adapter-test/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-adapter-test/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
labels: *adapter-labels
environment:
<<: *adapter-environment
TEST_SUITE: adapters
healthcheck:
test: ["CMD-SHELL", "test -d /root/.aidb/adapters && python -c 'import pytest; print(\"healthy\")'"]
interval: 10s
timeout: 5s
start_period: 10s
retries: 3
command: |
bash -lc '
set -euo pipefail
echo "🧪 Adapter Test Runner Started"
cd /workspace
python -m pip install -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/aidb/adapters/} \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
# ===========================
# MATRIX: Multi-version Testing
# ===========================
matrix-runner:
profiles: ["matrix"]
extends: test-runner
container_name: aidb-matrix-${MATRIX_ID:-default}
volumes:
- *workspace-mount
# Session-scoped to isolate logs from different test runs
- ${REPO_ROOT:-.}/.cache/container-data/aidb-matrix-${MATRIX_ID:-default}/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-matrix-${MATRIX_ID:-default}/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
labels: *test-labels
environment:
<<: *adapter-environment
TEST_SUITE: matrix
# Override versions for matrix testing
PYTHON_VERSION: ${MATRIX_PYTHON:-3.12}
NODE_VERSION: ${MATRIX_NODE:-22}
JAVA_VERSION: ${MATRIX_JAVA:-21}
healthcheck:
test:
[
"CMD-SHELL",
"python --version | grep -q ${PYTHON_VERSION} &&
node --version | grep -q v${NODE_VERSION} &&
java -version 2>&1 | grep -q ${JAVA_VERSION}",
]
interval: 10s
timeout: 5s
start_period: 15s
retries: 3
command: |
bash -lc '
set -euo pipefail
echo "🔬 Matrix Test Runner Started"
echo "Python: ${PYTHON_VERSION}, Node: ${NODE_VERSION}, Java: ${JAVA_VERSION}"
cd /workspace
python -m pip install -e .[test,dev] -q
python -m pytest src/tests/ \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
# ===========================
# UTILITIES: Helper Services
# ===========================
shell:
profiles: ["shell", "debug"]
extends: test-runner
container_name: aidb-shell
labels: *utility-labels
environment:
<<: *adapter-environment
AIDB_TEST_MODE: "1"
PS1: "\\[\\033[1;34m\\]aidb-docker\\[\\033[0m\\]:\\w$ "
healthcheck:
test: ["CMD-SHELL", "test -f /bin/bash && test -d /workspace"]
interval: 30s
timeout: 3s
start_period: 5s
retries: 2
command: bash
# ===========================
# LANGUAGE-SPECIFIC: Framework Testing per Language
# Generated from templates - do not edit manually
# ===========================
test-runner-java:
profiles: ["java", "frameworks", "launch"]
build:
context: ${REPO_ROOT:-../../..}
dockerfile: src/tests/_docker/dockerfiles/Dockerfile.test.java
args: *build-args
image: aidb-test-java:${IMAGE_TAG:-latest}
container_name: aidb-test-java
volumes:
- *workspace-mount
# Container-specific cache directories for parallel execution
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-java/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-java/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
# Build tool dependency caches (Maven/Gradle for Java)
- ${REPO_ROOT:-.}/.cache/maven/repository:/root/.m2/repository:rw
- ${REPO_ROOT:-.}/.cache/gradle:/root/.gradle:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
environment:
<<: *adapter-environment
TEST_SUITE: ${TEST_SUITE:-frameworks}
TEST_LANGUAGE: ${TEST_LANGUAGE:-java}
CONTAINER_NAME: aidb-test-java
working_dir: /workspace
networks:
- test-network
tmpfs:
- /tmp:exec
stdin_open: true
tty: true
labels: *test-labels
healthcheck:
test: ["CMD-SHELL", "java -version && test -f /root/.aidb/adapters/java/java-debug.jar"]
interval: 10s
timeout: 5s
start_period: 10s
retries: 3
command: |
bash -lc '
set -euo pipefail
echo "Java Test Runner Started"
cd /workspace
python -m pip install --root-user-action=ignore --break-system-packages -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/frameworks/java/} \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
test-runner-javascript:
profiles: ["javascript", "frameworks", "launch"]
build:
context: ${REPO_ROOT:-../../..}
dockerfile: src/tests/_docker/dockerfiles/Dockerfile.test.javascript
args: *build-args
image: aidb-test-javascript:${IMAGE_TAG:-latest}
container_name: aidb-test-javascript
volumes:
- *workspace-mount
# Container-specific cache directories for parallel execution
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-javascript/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-javascript/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
# Build tool dependency caches (Maven/Gradle for Java)
- ${REPO_ROOT:-.}/.cache/maven/repository:/root/.m2/repository:rw
- ${REPO_ROOT:-.}/.cache/gradle:/root/.gradle:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
environment:
<<: *adapter-environment
TEST_SUITE: ${TEST_SUITE:-frameworks}
TEST_LANGUAGE: ${TEST_LANGUAGE:-javascript}
CONTAINER_NAME: aidb-test-javascript
working_dir: /workspace
networks:
- test-network
tmpfs:
- /tmp:exec
stdin_open: true
tty: true
labels: *test-labels
healthcheck:
test: ["CMD-SHELL", "node --version && test -f /root/.aidb/adapters/javascript/src/dapDebugServer.js"]
interval: 10s
timeout: 5s
start_period: 10s
retries: 3
command: |
bash -lc '
set -euo pipefail
echo "Javascript Test Runner Started"
cd /workspace
python -m pip install --root-user-action=ignore --break-system-packages -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/frameworks/javascript/} \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
test-runner-python:
profiles: ["python", "frameworks", "launch"]
build:
context: ${REPO_ROOT:-../../..}
dockerfile: src/tests/_docker/dockerfiles/Dockerfile.test.python
args: *build-args
image: aidb-test-python:${IMAGE_TAG:-latest}
container_name: aidb-test-python
volumes:
- *workspace-mount
# Container-specific cache directories for parallel execution
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-python/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-test-python/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
# Build tool dependency caches (Maven/Gradle for Java)
- ${REPO_ROOT:-.}/.cache/maven/repository:/root/.m2/repository:rw
- ${REPO_ROOT:-.}/.cache/gradle:/root/.gradle:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
environment:
<<: *adapter-environment
TEST_SUITE: ${TEST_SUITE:-frameworks}
TEST_LANGUAGE: ${TEST_LANGUAGE:-python}
CONTAINER_NAME: aidb-test-python
working_dir: /workspace
networks:
- test-network
tmpfs:
- /tmp:exec
stdin_open: true
tty: true
labels: *test-labels
healthcheck:
test: ["CMD-SHELL", "python --version && test -d /root/.aidb/adapters/python"]
interval: 10s
timeout: 5s
start_period: 10s
retries: 3
command: |
bash -lc '
set -euo pipefail
echo "Python Test Runner Started"
cd /workspace
python -m pip install --root-user-action=ignore -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/frameworks/python/} \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
# Language-specific MCP runners (generated)
mcp-java:
profiles: ["mcp", "mcp-java"]
extends: mcp-test-runner
container_name: aidb-mcp-java
volumes:
- *workspace-mount
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-java/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-java/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
labels: *mcp-labels
environment:
<<: *adapter-environment
TEST_LANGUAGE: java
healthcheck:
test: ["CMD-SHELL", "java -version && test -f /root/.aidb/adapters/java/java-debug.jar"]
interval: 5s
timeout: 3s
start_period: 10s
retries: 3
command: |
bash -lc '
set -euo pipefail
cd /workspace
python -m pip install --root-user-action=ignore --break-system-packages -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/aidb_mcp/} -k java \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
mcp-javascript:
profiles: ["mcp", "mcp-javascript"]
extends: mcp-test-runner
container_name: aidb-mcp-javascript
volumes:
- *workspace-mount
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-javascript/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-javascript/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
labels: *mcp-labels
environment:
<<: *adapter-environment
TEST_LANGUAGE: javascript
healthcheck:
test: ["CMD-SHELL", "node --version && test -f /root/.aidb/adapters/javascript/src/dapDebugServer.js"]
interval: 5s
timeout: 3s
start_period: 10s
retries: 3
command: |
bash -lc '
set -euo pipefail
cd /workspace
python -m pip install --root-user-action=ignore --break-system-packages -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/aidb_mcp/} -k javascript \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
mcp-python:
profiles: ["mcp", "mcp-python"]
extends: mcp-test-runner
container_name: aidb-mcp-python
volumes:
- *workspace-mount
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-python/${PYTEST_SESSION_ID:-latest}/log:/root/.aidb/log:rw
- ${REPO_ROOT:-.}/.cache/container-data/aidb-mcp-python/${PYTEST_SESSION_ID:-latest}/pytest:/workspace/pytest-logs:rw
- *test-cache-mount
- *adapters-mount-rw
- *adapters-mount-ro
- *docker-socket-mount
labels: *mcp-labels
environment:
<<: *adapter-environment
TEST_LANGUAGE: python
healthcheck:
test: ["CMD-SHELL", "python --version && test -d /root/.aidb/adapters/python"]
interval: 5s
timeout: 3s
start_period: 10s
retries: 3
command: |
bash -lc '
set -euo pipefail
cd /workspace
python -m pip install --root-user-action=ignore -e .[test,dev] -q
python -m pytest ${TEST_PATH:-src/tests/aidb_mcp/} -k python \
--color=yes \
-o log_file=${PYTEST_LOG_DIR:-pytest-logs}/pytest-captured.log \
-v 2>&1 | tee ${PYTEST_LOG_DIR:-pytest-logs}/test-results.log
'
networks:
test-network:
driver: bridge
name: aidb-test-net
labels:
<<: *aidb-labels
com.aidb.type: "network"
ipam:
config:
- subnet: 172.28.0.0/16
volumes:
test-cache:
name: aidb-test-cache
labels:
<<: *aidb-labels
com.aidb.type: "cache"
adapter-cache:
name: aidb-adapter-cache
labels:
<<: *aidb-labels
com.aidb.type: "cache"