[Test] KT-61360: add tests for the IrFakeOverrideBuilder
Add tests for fake overrides with focus on java interoperability Co-authored-by: Aleksandra Arsenteva <aleksandra.arsenteva@jetbrains.com>
This commit is contained in:
committed by
Space Team
parent
30aae741a6
commit
82255d5ee8
Vendored
+43
@@ -0,0 +1,43 @@
|
||||
class A : Java1, Java2 {
|
||||
constructor() /* primary */ {
|
||||
super/*Java1*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class B : Java1, Java2 {
|
||||
constructor() /* primary */ {
|
||||
super/*Java1*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
override fun foo() {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class C : Java1, KotlinInterface {
|
||||
constructor() /* primary */ {
|
||||
super/*Java1*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
override fun foo() {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
interface KotlinInterface {
|
||||
abstract fun foo()
|
||||
|
||||
}
|
||||
|
||||
fun test(a: A, b: B, c: C) {
|
||||
a.foo()
|
||||
b.foo()
|
||||
c.foo()
|
||||
}
|
||||
Reference in New Issue
Block a user