public BigDecimal getJavaVersion() {
    String version = System.getProperty("java.specification.version");
    return new BigDecimal(version);
  }
Returns the current JVM's Java specification version.
Examples for valid values are {@code 1.6} and {@code 1.7}.

@return the current JVM's Java specification version
spock-core/src/main/java/org/spockframework/runtime/extension/builtin/PreconditionContext.java