Fixes to tests: forgotten package names and tests
This commit is contained in:
@@ -11,8 +11,8 @@ fun main(args: Array<String>) {
|
||||
checkClass(Any::class, "kotlin.Any", "Any", Any(), null)
|
||||
checkClass(Int::class, "kotlin.Int", "Int", 42, "17")
|
||||
checkClass(String::class, "kotlin.String", "String", "17", 42)
|
||||
checkClass(RootClass::class, "RootClass", "RootClass", RootClass(), Any())
|
||||
checkClass(RootClass.Nested::class, "RootClass.Nested", "Nested", RootClass.Nested(), Any())
|
||||
checkClass(RootClass::class, "codegen.kclass.kclass0.RootClass", "RootClass", RootClass(), Any())
|
||||
checkClass(RootClass.Nested::class, "codegen.kclass.kclass0.RootClass.Nested", "Nested", RootClass.Nested(), Any())
|
||||
|
||||
class Local {
|
||||
val captured = args
|
||||
@@ -33,7 +33,7 @@ fun main(args: Array<String>) {
|
||||
|
||||
// Interfaces:
|
||||
checkClass(Comparable::class, "kotlin.Comparable", "Comparable", 42, Any())
|
||||
checkClass(Interface::class, "Interface", "Interface", object : Interface {}, Any())
|
||||
checkClass(Interface::class, "codegen.kclass.kclass0.Interface", "Interface", object : Interface {}, Any())
|
||||
|
||||
checkInstanceClass(Any(), Any::class)
|
||||
checkInstanceClass(42, Int::class)
|
||||
|
||||
@@ -40,9 +40,9 @@ class App(testQualified: Boolean) {
|
||||
}
|
||||
|
||||
init {
|
||||
assert(type.simpleName == "Test")
|
||||
assert(type.simpleName == "TestClass")
|
||||
if (testQualified)
|
||||
assert(type.qualifiedName == "com.github.salomonbrys.kmffkn.Test") // This is not really necessary, but always better :).
|
||||
assert(type.qualifiedName == "codegen.kclass.kclass1.TestClass") // This is not really necessary, but always better :).
|
||||
|
||||
assert(String::class == String::class)
|
||||
assert(String::class != Int::class)
|
||||
|
||||
Reference in New Issue
Block a user