Temporary rollback to Kotlin 1.0.6

Kotlin 1.1-M04 has a bug that makes the generated bytecode
not compatible with Kotlin 1.0.x. This bug should be fixed in
Kotlin 1.1-M05.
This commit is contained in:
Sebastien Deleuze
2017-01-03 16:50:09 +01:00
parent d912f77a31
commit e78ea34711
2 changed files with 14 additions and 12 deletions

View File

@@ -6,7 +6,7 @@ buildscript {
dependencies {
classpath("org.springframework.build.gradle:propdeps-plugin:0.0.7")
classpath("org.asciidoctor:asciidoctor-gradle-plugin:1.5.3")
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.1-M04"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.0.6"
classpath("io.spring.gradle:docbook-reference-plugin:0.3.1")
}
}
@@ -70,7 +70,7 @@ configure(allprojects) { project ->
ext.junitVersion = "4.12"
ext.junitJupiterVersion = '5.0.0-M3'
ext.junitPlatformVersion = '1.0.0-M3'
ext.kotlinVersion = "1.1-M04" // Also change kotlin-gradle-plugin version when upgrading
ext.kotlinVersion = "1.0.6" // Also change kotlin-gradle-plugin version when upgrading
ext.log4jVersion = '2.7'
ext.nettyVersion = "4.1.6.Final"
ext.okhttpVersion = "2.7.5"
@@ -111,10 +111,10 @@ configure(allprojects) { project ->
// Kotlin compiler does not support JDK 9 yet, see https://youtrack.jetbrains.com/issue/KT-14988
if (!JavaVersion.current().java9Compatible) {
apply plugin: "kotlin"
compileKotlin {
kotlinOptions.apiVersion = 1.0
kotlinOptions.languageVersion = 1.0
}
//compileKotlin {
// kotlinOptions.apiVersion = 1.0
// kotlinOptions.languageVersion = 1.0
//}
}
configurations {
@@ -972,12 +972,12 @@ project("spring-webmvc") {
// Ideally, kotlin-script-runtime should be enough for JSR-223, but that's not
// the case yet, so we depend on kotlin-script-util and exclude these
// dependencies only used for artifact retrieval. Point raised to Kotlin team.
testRuntime("org.jetbrains.kotlin:kotlin-compiler:${kotlinVersion}")
testRuntime("org.jetbrains.kotlin:kotlin-script-util:${kotlinVersion}") {
exclude group: "com.jcabi", module: "jcabi-aether"
exclude group: "org.apache.maven", module: "maven-core"
exclude group: "org.sonatype.aether", module: "aether-api"
}
//testRuntime("org.jetbrains.kotlin:kotlin-compiler:${kotlinVersion}")
//testRuntime("org.jetbrains.kotlin:kotlin-script-util:${kotlinVersion}") {
// exclude group: "com.jcabi", module: "jcabi-aether"
// exclude group: "org.apache.maven", module: "maven-core"
// exclude group: "org.sonatype.aether", module: "aether-api"
//}
testRuntime("org.webjars:underscorejs:1.8.3")
testRuntime("org.glassfish:javax.el:3.0.1-b08")
testRuntime("com.sun.xml.bind:jaxb-core:${jaxbVersion}")

View File

@@ -22,6 +22,7 @@ import javax.servlet.ServletContext;
import static org.junit.Assert.assertEquals;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import static org.mockito.Mockito.mock;
@@ -38,6 +39,7 @@ import org.springframework.web.context.WebApplicationContext;
*
* @author Sebastien Deleuze
*/
@Ignore // Temporary disabled since Kotlin 1.1-M04 generates bytecode not Kotlin 1.0 compliant, will be enable as soon as Kotlin 1.1-M05 is available
public class KotlinScriptTemplateTests {
private WebApplicationContext webAppContext;