link test

This commit is contained in:
Alexander Gorshenev
2016-11-18 20:43:13 +03:00
committed by alexander-gorshenev
parent 72da55623c
commit 1e87dfeb8b
4 changed files with 21 additions and 3 deletions
+2 -3
View File
@@ -142,7 +142,7 @@ class LinkKonanTest extends KonanTest {
private File dir2bc(String ktSources) {
def sourcesKt = project.file(ktSources)
def libBc = new File("${sourcesKt.absolutePath}/bc/libout.kt.bc")
def libBc = new File("${sourcesKt.absolutePath}/libout.kt.bc")
def libPath = "${libBc.absolutePath}"
project.javaexec {
@@ -367,11 +367,10 @@ task intrinsic(type: UnitKonanTest) {
source = "codegen/function/intrinsic.kt"
}
/* TODO: fix test
task link(type: LinkKonanTest) {
source = "link/src/bar.kt"
lib = "link/lib"
} */
}
task for0(type: RunKonanTest) {
goldValue = "2\n3\n4\n"
+7
View File
@@ -0,0 +1,7 @@
package qwerty
fun foo(a: Int): Int {
return a
}
+7
View File
@@ -0,0 +1,7 @@
package qwerty
fun foo2(a: Int): Int {
return a
}
+5
View File
@@ -0,0 +1,5 @@
package qwerty
fun bar(a: Int): Int {
return foo(foo2(a))
}