mirror of
https://github.com/katanemo/plano.git
synced 2026-04-28 02:23:56 +02:00
49 lines
1 KiB
Bash
49 lines
1 KiB
Bash
|
|
#!/bin/bash
|
||
|
|
# Runs the openai responses API with state storage e2e test suite.
|
||
|
|
# Requires the plano Docker image to already be built/loaded.
|
||
|
|
set -e
|
||
|
|
|
||
|
|
. ./common_scripts.sh
|
||
|
|
|
||
|
|
print_disk_usage
|
||
|
|
|
||
|
|
mkdir -p ~/plano_logs
|
||
|
|
touch ~/plano_logs/modelserver.log
|
||
|
|
|
||
|
|
print_debug() {
|
||
|
|
log "Received signal to stop"
|
||
|
|
log "Printing debug logs for docker"
|
||
|
|
log "===================================="
|
||
|
|
tail -n 100 ../build.log 2>/dev/null || true
|
||
|
|
planoai logs --debug 2>/dev/null | tail -n 100 || true
|
||
|
|
}
|
||
|
|
|
||
|
|
trap 'print_debug' INT TERM ERR
|
||
|
|
|
||
|
|
log starting > ../build.log
|
||
|
|
|
||
|
|
# Install plano CLI
|
||
|
|
log "building and installing plano cli"
|
||
|
|
cd ../../cli
|
||
|
|
uv sync
|
||
|
|
uv tool install .
|
||
|
|
cd -
|
||
|
|
|
||
|
|
# Re-sync e2e deps
|
||
|
|
uv sync
|
||
|
|
|
||
|
|
# Start gateway with state storage config
|
||
|
|
log "startup arch gateway with state storage config"
|
||
|
|
cd ../../
|
||
|
|
planoai down || true
|
||
|
|
planoai up tests/e2e/config_memory_state_v1_responses.yaml
|
||
|
|
cd -
|
||
|
|
|
||
|
|
# Run tests
|
||
|
|
log "running e2e tests for openai responses api with state"
|
||
|
|
uv run pytest test_openai_responses_api_client_with_state.py
|
||
|
|
|
||
|
|
# Cleanup
|
||
|
|
log "shutting down"
|
||
|
|
planoai down || true
|