[Resolved] Caused by: java.lang.NoClassDefFoundError: java util HashMap$Entry - GolovchenkoA/todo GitHub Wiki

when i execute command gradlew test

i got an error:

FAILURE: Build failed with an exception.

  • Where: Script 'C:\java-projects\todo\gradle\envConfig.gradle' line: 4

  • What went wrong: A problem occurred evaluating script.

java/util/HashMap$Entry

when i execute command gradlew.bat test --stacktrace

i got an error: Caused by: java.lang.NoClassDefFoundError: java/util/HashMap$Entry

Next links describes similar issue
https://github.com/nextflow-io/nextflow/issues/7 https://discuss.gradle.org/t/gradle-fails-on-jdk8-with-java-lang-classnotfoundexception-java-util-hashmap-entry/2271 http://androidstudio2.blogspot.com/2014/08/caused-by-javalangnoclassdeffounderror.html

I think couse problem becouse i have installed java 8, whitch incompatibile with groovy 2

My Workaround:

  1. Download and install jdk1.7.0_80
  2. Execute with jdk 7 gradlew.bat build -Dorg.gradle.java.home="C:/Program Files (x86)/Java/jdk1.7.0_80"