Added regression tests for KT-2474 Range lacks reverse() in JavaScript backend

#KT-2474 Fixed
This commit is contained in:
Zalim Bashorov
2014-10-21 22:14:57 +04:00
parent 66519d9973
commit 8067a9ad56
2 changed files with 12 additions and 0 deletions
@@ -57,4 +57,8 @@ public final class RangeTest extends SingleFileTranslationTest {
public void testIntDownTo() throws Exception {
checkFooBoxIsOk();
}
public void testReverse() throws Exception {
checkFooBoxIsOk();
}
}
@@ -0,0 +1,8 @@
package foo
fun box(): String {
assertEquals(listOf(7, 6, 5, 4, 3), (3..7).reverse())
assertEquals(listOf(10, 11, 12, 13), (13 downTo 10).reverse())
return "OK"
}