migrated most of the test cases over to the new -> syntax for functions; still can't compile or run the tests yet though :(, needs more work...

This commit is contained in:
James Strachan
2011-12-21 16:26:37 +00:00
parent aaf18bdd86
commit 894c84190a
8 changed files with 135 additions and 132 deletions
+2 -2
View File
@@ -23,7 +23,7 @@ class SetTest() : TestSupport() {
data.all{it.length == 3}
}
assertNot {
data.all{s => s.startsWith("b")}
data.all{(s: String) -> s.startsWith("b")}
}
}
@@ -59,7 +59,7 @@ class SetTest() : TestSupport() {
we should be able to remove the explicit type on the function
http://youtrack.jetbrains.net/issue/KT-849
*/
val lengths = data.map<String,Int>{s => s.length}
val lengths = data.map<String,Int>{(s: String) -> s.length}
assert {
lengths.all{it == 3}
}