Make connectivity test faster
Replace --rerun-tasks with cleanTest to avoid re-executing
all dependent tasks. Add --no-build-cache as well based
on research, although it doesn't seem to matter in practice.
@@ -22,7 +22,10 @@ export JAVA_HOME="/opt/java/jdk11"
./gradlew -version
for MONGODB_URI in $@; do
- ./gradlew -PjdkHome=/opt/java/${JDK} -Dorg.mongodb.test.uri=${MONGODB_URI} --stacktrace --info --rerun-tasks driver-sync:test --tests ConnectivityTest
- ./gradlew -PjdkHome=/opt/java/${JDK} -Dorg.mongodb.test.uri=${MONGODB_URI} --stacktrace --info --rerun-tasks driver-legacy:test --tests ConnectivityTest
- ./gradlew -PjdkHome=/opt/java/${JDK} -Dorg.mongodb.test.uri=${MONGODB_URI} --stacktrace --info --rerun-tasks driver-reactive-streams:test --tests ConnectivityTest
+ ./gradlew -PjdkHome=/opt/java/${JDK} -Dorg.mongodb.test.uri=${MONGODB_URI} --stacktrace --info \
+ --no-build-cache driver-sync:cleanTest driver-sync:test --tests ConnectivityTest
+ ./gradlew -PjdkHome=/opt/java/${JDK} -Dorg.mongodb.test.uri=${MONGODB_URI} --stacktrace --info \
+ --no-build-cache driver-legacy:cleanTest driver-legacy:test --tests ConnectivityTest
+ ./gradlew -PjdkHome=/opt/java/${JDK} -Dorg.mongodb.test.uri=${MONGODB_URI} --stacktrace --info \
+ --no-build-cache driver-reactive-streams:cleanTest driver-reactive-streams:test --tests ConnectivityTest
done
