Make it possible to run hmpp tests with ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE
In scope of KT-40904 KT-55177 Review: https://jetbrains.team/p/kt/reviews/8731 In order to make it possible to run hmpp tests with `ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE`, a dependency manager must be implemented. This commit implements some basic dependency manager. I'm not sure in its correctness because `CommonDependenciesContainer` is an awkward API, but this dependency manager works for my cases. Why: I need hmpp + `ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE` infrastructure to cover `ExpectActualInTheSameModuleChecker` (I will add the checker in the next commit) with tests. The checker couldn't be covered with regular hmpp tests because regular hmpp tests and `K2MetadataCompiler` run the compiler in a different way. Contrary, `ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE` runs the compiler in a way `K2MetadataCompiler` does it. I moved some tests from hmpp to `hmpp/multiplatformCompositeAnalysis` because otherwise the tests would fail after I implement `ExpectActualInTheSameModuleChecker` in the next commit. Also the descriptor dumps were changed (intermediateWithActualAndExpect.txt and sealedInheritorsInComplexModuleStructure.txt). It happened because now common source sets are no longer "squashed" into a single source set but rather correct dependencies between source sets are established. And each source set is analyzed separately (exactly like in K2MetadataCompiler)
This commit is contained in:
-19
@@ -16,12 +16,6 @@ public final expect class B {
|
||||
// -- Module: <intermediate> --
|
||||
package
|
||||
|
||||
public final expect class A {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final actual class B {
|
||||
public constructor B()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
@@ -29,12 +23,6 @@ public final actual class B {
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final expect class B {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final expect class C {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
@@ -51,13 +39,6 @@ public final actual class A {
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final actual class B {
|
||||
public constructor B()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final actual class C {
|
||||
public constructor C()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
-27
@@ -22,12 +22,6 @@ package
|
||||
|
||||
package foo {
|
||||
|
||||
public sealed expect class SealedWithPlatformActuals : foo.SealedWithSharedActual {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public sealed actual class SealedWithSharedActual {
|
||||
protected constructor SealedWithSharedActual()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
@@ -35,13 +29,6 @@ package foo {
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public sealed expect class SealedWithSharedActual {
|
||||
protected constructor SealedWithSharedActual()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class SimpleShared : foo.SealedWithPlatformActuals {
|
||||
public constructor SimpleShared()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
@@ -61,19 +48,5 @@ package foo {
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public sealed actual class SealedWithSharedActual {
|
||||
protected constructor SealedWithSharedActual()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class SimpleShared : foo.SealedWithPlatformActuals {
|
||||
public constructor SimpleShared()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user