Hello all, I'm trying to run the tests, but it's g...
# getting-started
r
Hello all, I'm trying to run the tests, but it's giving the following error.
Copy code
Cannot inline bytecode built with JVM target 17 into bytecode that is being built with JVM target 1.8. Please specify proper '-jvm-target' option
my config
Copy code
tasks {
    test { useJUnitPlatform() }
    compileKotlin { kotlinOptions.jvmTarget = "17" }
    ...
}
What am I doing wrong?
e
tests aren't compiled by
compileKotlin
, they're compiled by
compileTestKotlin
✔️ 1
you should use
Copy code
kotlin.target.compilations.all {
    kotlinOptions.jvmTarget = "17"
}
instead
r
Thanks a lot @ephemient
e
or change wherever the inline function is coming from to target a lower jvm
835 Views