Uncomment some assertions for overflow behavior that now can pass in JS

This commit is contained in:
Ilya Gorbunov
2016-12-20 23:01:34 +03:00
parent 6b509892cb
commit c43e4f6682
2 changed files with 12 additions and 12 deletions
+2 -3
View File
@@ -70,7 +70,7 @@ public class RangeTest {
assertFalse(10.toByte() in openRange)
// byte arguments now construct IntRange so no overflow here
// assertTrue(assertFails { 0.toByte() until Byte.MIN_VALUE } is IllegalArgumentException)
assertTrue((0.toByte() until Byte.MIN_VALUE).isEmpty())
assertTrue((0.toByte() until Int.MIN_VALUE).isEmpty())
}
@@ -103,8 +103,7 @@ public class RangeTest {
assertTrue(9.toShort() in openRange)
assertFalse(10.toShort() in openRange)
// short arguments now construct IntRange so no overflow here
// assertTrue(assertFails { 0.toShort() until Short.MIN_VALUE } is IllegalArgumentException)
assertTrue((0.toShort() until Short.MIN_VALUE).isEmpty())
assertTrue((0.toShort() until Int.MIN_VALUE).isEmpty())
}