[java] fix tests
[java] remove unused main class