-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
OIDC Add remaining environments (azure, gcp), evergreen testing, API …
…naming updates (#1371) JAVA-5353 JAVA-5395 JAVA-4834 JAVA-4932 --------- Co-authored-by: Valentin Kovalenko <valentin.male.kovalenko@gmail.com>
- Loading branch information
Showing
16 changed files
with
1,186 additions
and
383 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
#!/bin/bash | ||
|
||
set +x # Disable debug trace | ||
set -eu | ||
|
||
echo "Running MONGODB-OIDC authentication tests" | ||
echo "OIDC_ENV $OIDC_ENV" | ||
|
||
if [ $OIDC_ENV == "test" ]; then | ||
if [ -z "$DRIVERS_TOOLS" ]; then | ||
echo "Must specify DRIVERS_TOOLS" | ||
exit 1 | ||
fi | ||
source ${DRIVERS_TOOLS}/.evergreen/auth_oidc/secrets-export.sh | ||
# java will not need to be installed, but we need to config | ||
RELATIVE_DIR_PATH="$(dirname "${BASH_SOURCE:-$0}")" | ||
source "${RELATIVE_DIR_PATH}/javaConfig.bash" | ||
elif [ $OIDC_ENV == "azure" ]; then | ||
source ./env.sh | ||
elif [ $OIDC_ENV == "gcp" ]; then | ||
source ./secrets-export.sh | ||
else | ||
echo "Unrecognized OIDC_ENV $OIDC_ENV" | ||
exit 1 | ||
fi | ||
|
||
|
||
if ! which java ; then | ||
echo "Installing java..." | ||
sudo apt install openjdk-17-jdk -y | ||
echo "Installed java." | ||
fi | ||
|
||
which java | ||
export OIDC_TESTS_ENABLED=true | ||
|
||
./gradlew -Dorg.mongodb.test.uri="$MONGODB_URI" \ | ||
--stacktrace --debug --info --no-build-cache driver-core:cleanTest \ | ||
driver-sync:test --tests OidcAuthenticationProseTests --tests UnifiedAuthTest \ | ||
driver-reactive-streams:test --tests OidcAuthenticationAsyncProseTests \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.