diff --git a/.evergreen/config.yml b/.evergreen/config.yml index 07ac1e8..8146e23 100644 --- a/.evergreen/config.yml +++ b/.evergreen/config.yml @@ -108,6 +108,11 @@ tasks: - func: "fetch repo" - func: "execute tests" + - name: test-autogen + commands: + - func: "fetch repo" + - func: "execute tests" + buildvariants: - name: test-semantic-kernel-python-rhel display_name: Semantic-Kernel RHEL Python @@ -180,4 +185,16 @@ buildvariants: run_on: - rhel87-small tasks: - - name: test-docarray \ No newline at end of file + - name: test-docarray + + - name: test-autogen-rhel + display_name: Autogen RHEL + expansions: + DIR: autogen + REPO_NAME: autogen # TODO [PYTHON-4506] Switch to https://github.com/microsoft/autogen.git one merged + CLONE_URL: https://github.com/ranfysvalle02/autogen.git + DATABASE: autogen_test_db + run_on: + - rhel87-small + tasks: + - name: test-autogen \ No newline at end of file diff --git a/autogen/database/autogen_test_vectorstore.json b/autogen/database/autogen_test_vectorstore.json new file mode 100644 index 0000000..0637a08 --- /dev/null +++ b/autogen/database/autogen_test_vectorstore.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/autogen/run.sh b/autogen/run.sh new file mode 100644 index 0000000..a157f39 --- /dev/null +++ b/autogen/run.sh @@ -0,0 +1,23 @@ +#!/bin/sh + +# Sets up a virtual environment +# Runs the mongodb tests of the upstream repo +# NOTE: In this instance, the tests *programmtically* create_vector_search_index + +set -x + +. $workdir/src/.evergreen/utils.sh +PYTHON_BINARY=$(find_python3) +$PYTHON_BINARY -c "import sys; print(f'Python version found: {sys.version_info}')" + +# Create and activate an isolated python venv environment +$PYTHON_BINARY -m venv venv +source venv/bin/activate +# Install autogen with extras +$PYTHON_BINARY -m pip install .[test,"retrievechat-mongodb"] + + +# Run tests. Sensitive variables in Evergreen come from Evergreen project: ai-ml-pipeline-testing/ +MONGODB_URI=$autogen_mongodb_uri \ +MONGODB_DATABASE="autogen_test_db" \ +$PYTHON_BINARY -m pytest -v test/agentchat/contrib/vectordb/test_mongodb.py