Skip to content

Commit

Permalink
Added e2e tests GH action, with docker compose build
Browse files Browse the repository at this point in the history
  • Loading branch information
dividor committed Jun 29, 2024
1 parent 79d130e commit 9cea28e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 10 deletions.
14 changes: 6 additions & 8 deletions .github/workflows/e2e_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,6 @@ jobs:
echo "Remove __pycache__ files"
sudo find . -type d -name __pycache__ -exec rm -r {} \+
fi
DOMAIN=backend \
SMTP_HOST="" \
TRAEFIK_PUBLIC_NETWORK_IS_EXTERNAL=false \
INSTALL_DEV=true \
docker-compose \
-f docker-compose.yml -f docker-compose-dev.yml \
config > docker-stack.yml
Expand All @@ -109,9 +105,11 @@ jobs:
docker ps
echo "logs backend ..."
docker-compose -f docker-stack.yml logs server
#echo "Tests ..."
#docker-compose -f docker-stack.yml exec -T backend /app/tests-start.sh --ignore=app/tests/api/api_v1/self/ "$@" -s
#echo "Logs backend ..."
docker-compose -f docker-stack.yml logs backend
echo "Tests ..."
docker compose -f docker-compose.yml -f docker-compose-dev.yml exec --workdir /app/chainlit-ui-evaluation promptflow pf run create --flow . --data ./data.jsonl --stream --column-mapping query='${data.query}' context='${data.context}' chat_history='${data.chat_history}' --name base_run
docker compose -f docker-compose.yml -f docker-compose-dev.yml exec --workdir /app/chainlit-ui-evaluation pf run show-details -n base_run
docker compose -f docker-compose.yml -f docker-compose-dev.yml exec --workdir /app/chainlit-ui-evaluation pf run show-metrics -n base_run
docker compose -f docker-compose.yml -f docker-compose-dev.yml exec --workdir /app/chainlit-ui-evaluation pf run visualize -n base_run
docker compose -f docker-compose.yml -f docker-compose-dev.yml exec --workdir /app/chainlit-ui-evaluation python3 check_evaluation_results.py
docker-compose -f docker-stack.yml down -v --remove-orphans
3 changes: 1 addition & 2 deletions docker-compose-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@

services:
promptflow:
#image: mcr.microsoft.com/azureml/promptflow/promptflow-runtime-stable:latest
build:
context: .
dockerfile: ./flows/chainlit-ui-evaluation//Dockerfile
args:
OPENAI_API_KEY: ${ASSISTANTS_API_KEY}
OPENAI_API_KEY: ${OPENAI_API_KEY}
OPENAI_API_ENDPOINT: ${ASSISTANTS_BASE_URL}
container_name: recipes-ai-promptflow
env_file:
Expand Down

0 comments on commit 9cea28e

Please sign in to comment.