Skip to content

Commit 4005292

Browse files
committed
Simplify driver detection logic
1 parent fb2efed commit 4005292

File tree

1 file changed

+11
-17
lines changed

1 file changed

+11
-17
lines changed

.evergreen/run-tests.sh

Lines changed: 11 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -17,23 +17,17 @@ IS_MATRIX_TESTING=${IS_MATRIX_TESTING:-false}
1717

1818
# For matrix testing, we have to determine the correct driver version
1919
if [ "$IS_MATRIX_TESTING" == "true" ]; then
20-
set_extension_version () {
21-
case $1 in
22-
'4.4')
23-
export DRIVER_VERSION='1.8.2'
24-
;;
25-
'4.2')
26-
export DRIVER_VERSION='1.6.1'
27-
;;
28-
'4.0')
29-
export DRIVER_VERSION='1.5.5'
30-
;;
31-
esac
32-
}
33-
34-
set_extension_version "${DRIVER_MONGODB_VERSION}"
35-
36-
echo $DRIVER_VERSION
20+
case "${DRIVER_MONGODB_VERSION}" in
21+
'4.4')
22+
export DRIVER_VERSION='1.8.2'
23+
;;
24+
'4.2')
25+
export DRIVER_VERSION='1.6.1'
26+
;;
27+
'4.0')
28+
export DRIVER_VERSION='1.5.5'
29+
;;
30+
esac
3731

3832
DIR=$(dirname $0)
3933
. $DIR/install-dependencies.sh

0 commit comments

Comments
 (0)