Cleanup deprecated symbol usages in testData

This commit is contained in:
Ilya Gorbunov
2016-01-16 20:10:40 +03:00
parent eefbd72a64
commit 25c4453dc5
403 changed files with 933 additions and 921 deletions
@@ -6,7 +6,7 @@ annotation class Anno
fun box(): String {
val a = Anno::class.annotations
if (a.size() != 1) return "Fail 1: $a"
if (a.size != 1) return "Fail 1: $a"
val ann = a.single() as? Retention ?: return "Fail 2: ${a.single()}"
assertEquals(AnnotationRetention.RUNTIME, ann.value)
@@ -13,6 +13,6 @@ annotation class RuntimeAnno
@BinaryAnno
@RuntimeAnno
fun box(): String {
assertEquals(listOf(javaClass<RuntimeAnno>()), ::box.annotations.map { it.annotationType() })
assertEquals(listOf(RuntimeAnno::class.java), ::box.annotations.map { it.annotationClass.java })
return "OK"
}
@@ -7,7 +7,7 @@ class C @Primary constructor() {
}
fun box(): String {
val ans = C::class.constructors.map { it.annotations.single().annotationType().simpleName }.sorted()
val ans = C::class.constructors.map { it.annotations.single().annotationClass.java.simpleName }.sorted()
if (ans != listOf("Primary", "Secondary")) return "Fail: $ans"
return "OK"
}