85827b4880
This patch copies Kotlin/JVM stdlib tests (libraries/stdlib/test) excepting ones with explicit java dependencies. It also transforms the tests to use them as box-tests.
21 lines
406 B
Kotlin
21 lines
406 B
Kotlin
import kotlin.test.*
|
|
import kotlin.comparisons.*
|
|
|
|
fun box() {
|
|
val data = arrayListOf<String>()
|
|
data.reverse()
|
|
assertTrue(data.isEmpty())
|
|
|
|
data.add("foo")
|
|
data.reverse()
|
|
assertEquals(listOf("foo"), data)
|
|
|
|
data.add("bar")
|
|
data.reverse()
|
|
assertEquals(listOf("bar", "foo"), data)
|
|
|
|
data.add("zoo")
|
|
data.reverse()
|
|
assertEquals(listOf("zoo", "foo", "bar"), data)
|
|
}
|