Cleanup deprecated symbol usages in testData
This commit is contained in:
@@ -118,7 +118,7 @@ fun box(): String {
|
||||
asSucceeds("mentry as MutableMap.MutableEntry") { mentry as MutableMap.MutableEntry<*, *> }
|
||||
|
||||
hashMap[""] = ""
|
||||
val hashMapEntry = hashMap.entrySet().first()
|
||||
val hashMapEntry = hashMap.entries.first()
|
||||
|
||||
asSucceeds("hashMapEntry as MutableMap.MutableEntry") { hashMapEntry as MutableMap.MutableEntry<*, *> }
|
||||
|
||||
|
||||
@@ -96,7 +96,7 @@ fun box(): String {
|
||||
val mentry = MME()
|
||||
|
||||
hashMap[""] = ""
|
||||
val hashMapEntry = hashMap.entrySet().first()
|
||||
val hashMapEntry = hashMap.entries.first()
|
||||
|
||||
assert(entry !is MutableMap.MutableEntry<*, *>) { "ME should satisfy '!is MutableMap.MutableEntry'"}
|
||||
assert(mentry is MutableMap.MutableEntry<*, *>) { "MME should satisfy 'is MutableMap.MutableEntry'"}
|
||||
|
||||
@@ -118,7 +118,7 @@ fun box(): String {
|
||||
val mentry = MME()
|
||||
|
||||
hashMap[""] = ""
|
||||
val hashMapEntry = hashMap.entrySet().first()
|
||||
val hashMapEntry = hashMap.entries.first()
|
||||
|
||||
reifiedAsFailsWithCCE<MutableMap.MutableEntry<*, *>>(entry, "reifiedAs<MutableMap.MutableEntry<*, *>>(entry)")
|
||||
reifiedAsSucceeds<MutableMap.MutableEntry<*, *>>(mentry, "reifiedAs<MutableMap.MutableEntry<*, *>>(mentry)")
|
||||
|
||||
@@ -99,7 +99,7 @@ fun box(): String {
|
||||
val mentry = MME()
|
||||
|
||||
hashMap[""] = ""
|
||||
val hashMapEntry = hashMap.entrySet().first()
|
||||
val hashMapEntry = hashMap.entries.first()
|
||||
|
||||
assert(reifiedIsNot<MutableMap.MutableEntry<*, *>>(entry)) { "reifiedIsNot<MutableMap.MutableEntry<*, *>>(entry)"}
|
||||
assert(reifiedIs<MutableMap.MutableEntry<*, *>>(mentry)) { "reifiedIs<MutableMap.MutableEntry<*, *>>(mentry)"}
|
||||
|
||||
@@ -120,7 +120,7 @@ fun box(): String {
|
||||
val mentry = MME()
|
||||
|
||||
hashMap[""] = ""
|
||||
val hashMapEntry = hashMap.entrySet().first()
|
||||
val hashMapEntry = hashMap.entries.first()
|
||||
|
||||
reifiedSafeAsReturnsNull<MutableMap.MutableEntry<*, *>>(entry, "reifiedSafeAs<MutableMap.MutableEntry<*, *>>(entry)")
|
||||
reifiedSafeAsReturnsNonNull<MutableMap.MutableEntry<*, *>>(mentry, "reifiedSafeAs<MutableMap.MutableEntry<*, *>>(mentry)")
|
||||
|
||||
@@ -117,7 +117,7 @@ fun box(): String {
|
||||
safeAsReturnsNonNull("mentry as? MutableMap.MutableEntry") { mentry as? MutableMap.MutableEntry<*, *> }
|
||||
|
||||
hashMap[""] = ""
|
||||
val hashMapEntry = hashMap.entrySet().first()
|
||||
val hashMapEntry = hashMap.entries.first()
|
||||
|
||||
safeAsReturnsNonNull("hashMapEntry as? MutableMap.MutableEntry") { hashMapEntry as? MutableMap.MutableEntry<*, *> }
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ fun box(): String {
|
||||
return "OK"
|
||||
}
|
||||
catch (e: Throwable) {
|
||||
return "Fail: ClassCastException should have been thrown, but was instead ${e.javaClass.getName()}: ${e.getMessage()}"
|
||||
return "Fail: ClassCastException should have been thrown, but was instead ${e.javaClass.getName()}: ${e.message}"
|
||||
}
|
||||
|
||||
return "Fail: no exception was thrown"
|
||||
|
||||
Reference in New Issue
Block a user