Upgrade java mockito from version 1.x to version 5 (#2781)

* use mockito 5

* remove unnecessary flag

* fix java annotation test file name
diff --git a/lib/java/gradle.properties b/lib/java/gradle.properties
index 917b24b..4256dbd 100644
--- a/lib/java/gradle.properties
+++ b/lib/java/gradle.properties
@@ -31,7 +31,7 @@
 servlet.version=4.0.1
 tomcat.embed.version=9.0.43
 junit.version=5.8.2
-mockito.version=1.10.19
+mockito.version=5.3.0
 javax.annotation.version=1.3.2
 commons-lang3.version=3.12.0