Remote test execution for cross compiled tests. Run it like:

$ ./gradlew backend.native:tests:run \
    -Premote=user@111.22.33.444 -Ptest_target=raspberrypi

The new gradle command line options:

    -Pbuild_flags  renamed -Pkonanc_flags.
    -Ptest_flags   provides compiler flags to the test builds.
    -Ptest_target  properly sets up compiler as well as interop
                   to cross compile tests.
    -Premote       specifies remote host and login.
This commit is contained in:
Alexander Gorshenev
2017-03-22 17:57:40 +03:00
committed by alexander-gorshenev
parent 826b3fc3f2
commit 334d2f0ee6
11 changed files with 171 additions and 37 deletions
+8
View File
@@ -29,6 +29,8 @@ ext.testOutputRoot = rootProject.file("test.output").absolutePath
ext.externalTestsDir = project.file("external")
externalTestsDir.mkdirs()
project.convention.plugins.remoteExec = new org.jetbrains.kotlin.ExecRemote(project)
allprojects {
// Root directories for test output (logs, compiled files, statistics etc). Only single path must be in each set.
sourceSets {
@@ -1604,6 +1606,12 @@ task interop2(type: RunInteropKonanTest) {
}
task interop3(type: RunInteropKonanTest) {
// We disable this test on Raspberry Pi because
// qsort accepts size_t args. So the .kt file
// should be different depending on the bitness of the target.
// There are plans to provide a solution and turn this
// test back on.
disabled = (project.testTarget == 'raspberrypi')
goldValue = "8 9 12 13 14 \n"
source = "interop/basics/3.kt"
interop = 'cstdlib'
+1 -1
View File
@@ -26,4 +26,4 @@ private fun comparator(a: COpaquePointer?, b: COpaquePointer?): Int {
val bValue = b!!.reinterpret<CInt32Var>().pointed.value
return (aValue - bValue)
}
}