@@ -53,6 +53,7 @@ functions:
5353 if [ "Windows_NT" = "$OS" ]; then # Magic variable in cygwin
5454 # Python has cygwin path problems on Windows. Detect prospective mongo-orchestration home directory
5555 export DRIVERS_TOOLS=$(cygpath -m $DRIVERS_TOOLS)
56+ export DOTNET_SDK_PATH=$(cygpath -m $DOTNET_SDK_PATH)
5657 else
5758 # non windows OSs don't have dotnet in the PATH
5859 export PATH=$PATH:/usr/share/dotnet
@@ -72,6 +73,7 @@ functions:
7273 PROJECT_DIRECTORY: "$PROJECT_DIRECTORY"
7374 PACKAGE_VERSION: "$PACKAGE_VERSION"
7475 DOTNET_SDK_PATH: "$DOTNET_SDK_PATH"
76+ TEST_RESULTS_PATH: "./mongo-csharp-driver/build/test-results/TEST-*.xml"
7577 PREPARE_SHELL: |
7678 set -o errexit
7779 set -o xtrace
@@ -146,6 +148,21 @@ functions:
146148 ${PREPARE_SHELL}
147149 ${PROJECT_DIRECTORY}/${file}
148150
151+ run-external-script :
152+ - command : subprocess.exec
153+ type : test
154+ params :
155+ working_dir : mongo-csharp-driver
156+ binary : bash
157+ include_expansions_in_env :
158+ - " OS"
159+ - " GIT_REPO"
160+ - " GIT_BRANCH"
161+ - " LOCAL_PATH"
162+ - " SCRIPT"
163+ args :
164+ - evergreen/run-external-script.sh
165+
149166 upload-mo-artifacts :
150167 - command : shell.exec
151168 params :
@@ -210,7 +227,7 @@ functions:
210227 upload-test-results :
211228 - command : attach.xunit_results
212229 params :
213- file : ./mongo-csharp-driver/build/test-results/TEST-*.xml
230+ file : ${TEST_RESULTS_PATH}
214231
215232 bootstrap-mongo-orchestration :
216233 - command : shell.exec
@@ -1871,6 +1888,23 @@ tasks:
18711888 - func : install-dotnet
18721889 - func : build-apidocs
18731890
1891+ - name : test-odata
1892+ commands :
1893+ - func : bootstrap-mongo-orchestration
1894+ - command : expansions.update
1895+ params :
1896+ updates :
1897+ - key : TEST_RESULTS_PATH
1898+ value : " ./odata/build/test-results/TEST-*.xml"
1899+ - func : run-external-script
1900+ vars :
1901+ GIT_REPO : " https://github.com/mongodb/mongo-aspnetcore-odata.git"
1902+ LOCAL_PATH : ${workdir}/odata
1903+ SCRIPT : |
1904+ ${PREPARE_SHELL}
1905+ DOTNET_SDK_PATH="${DOTNET_SDK_PATH}" bash ./evergreen/install-dependencies.sh
1906+ DRIVER_VERSION="${PACKAGE_VERSION}" bash ./evergreen/run-tests.sh
1907+
18741908axes :
18751909 - id : version
18761910 display_name : MongoDB Version
@@ -2731,4 +2765,20 @@ buildvariants:
27312765 git_tag_only : true
27322766 depends_on :
27332767 - name : push-packages-nuget
2734- variant : " .push-packages"
2768+ variant : " .push-packages"
2769+
2770+ - matrix_name : odata-tests
2771+ batchtime : 720 # 12 hours
2772+ matrix_spec :
2773+ os : ["ubuntu-2004", "windows-64"]
2774+ version : ["4.2", "7.0", "latest"]
2775+ exclude_spec :
2776+ # We do not have MongoDB 4.2 binaries for Ubuntu 2004
2777+ - os : " ubuntu-2004"
2778+ version : " 4.2"
2779+ display_name : " OData tests on ${os} with MongoDB ${version}"
2780+ tasks :
2781+ - name : test-odata
2782+ depends_on :
2783+ - name : push-packages-myget
2784+ variant : " .push-packages-myget"
0 commit comments