From fb5d8de84b5214b9b30457fbe0985f820a138cb8 Mon Sep 17 00:00:00 2001 From: Alexander Udalov Date: Fri, 9 Oct 2015 03:59:27 +0300 Subject: [PATCH] Use type table in DescriptorSerializer, add switch to enable/disable, test --- .../kotlin/codegen/ClosureCodegen.java | 4 +- .../codegen/ImplementationBodyCodegen.java | 4 +- .../codegen/MultifileClassPartCodegen.kt | 4 +- .../kotlin/codegen/PackageCodegen.java | 4 +- .../kotlin/codegen/PackagePartCodegen.java | 4 +- .../serialization/JvmSerializerExtension.java | 9 +- .../kotlin/codegen/state/GenerationState.kt | 1 + .../builtins/BuiltInsSerializer.kt | 21 +- .../builtins/BuiltInsSerializerExtension.kt | 2 + .../compiler/KotlinToJVMBytecodeCompiler.java | 1 + .../asJava/KotlinJavaFileStubProvider.java | 1 + .../serialization/DescriptorSerializer.java | 139 +- .../kotlin/serialization/MutableTypeTable.kt | 45 + .../serialization/SerializerExtension.java | 4 + .../kotlin/codegen/CodegenTestUtil.java | 3 +- .../kotlin/codegen/GenerationUtils.java | 13 +- .../jvm/compiler/AbstractLoadJavaTest.java | 21 +- .../AbstractLoadKotlinWithTypeTableTest.kt | 23 + .../jvm/compiler/LoadDescriptorUtil.java | 9 +- .../LoadKotlinWithTypeTableTestGenerated.java | 3088 +++++++++++++++++ .../AbstractLocalClassProtoTest.kt | 2 +- .../jetbrains/kotlin/test/JetTestUtils.java | 2 +- .../org/jetbrains/kotlin/utils/Interner.java | 4 + .../kotlin/generators/tests/GenerateTests.kt | 4 + .../internal/KotlinBytecodeToolWindow.java | 1 + 25 files changed, 3360 insertions(+), 53 deletions(-) create mode 100644 compiler/serialization/src/org/jetbrains/kotlin/serialization/MutableTypeTable.kt create mode 100644 compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadKotlinWithTypeTableTest.kt create mode 100644 compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadKotlinWithTypeTableTestGenerated.java diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/ClosureCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/ClosureCodegen.java index 5086515439b..0973b3a6a3c 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/ClosureCodegen.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/ClosureCodegen.java @@ -222,7 +222,9 @@ public class ClosureCodegen extends MemberCodegen { writeKotlinSyntheticClassAnnotation(v, state); DescriptorSerializer serializer = - DescriptorSerializer.createTopLevel(new JvmSerializerExtension(v.getSerializationBindings(), typeMapper)); + DescriptorSerializer.createForLambda( + new JvmSerializerExtension(v.getSerializationBindings(), typeMapper, state.getUseTypeTableInSerializer()) + ); ProtoBuf.Function functionProto = serializer.functionProto(funDescriptor).build(); diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/ImplementationBodyCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/ImplementationBodyCodegen.java index 19c10964624..98e0e6f87e5 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/ImplementationBodyCodegen.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/ImplementationBodyCodegen.java @@ -256,7 +256,9 @@ public class ImplementationBodyCodegen extends ClassBodyCodegen { } DescriptorSerializer serializer = - DescriptorSerializer.create(descriptor, new JvmSerializerExtension(v.getSerializationBindings(), typeMapper)); + DescriptorSerializer.create(descriptor, new JvmSerializerExtension( + v.getSerializationBindings(), typeMapper, state.getUseTypeTableInSerializer() + )); ProtoBuf.Class classProto = serializer.classProto(descriptor).build(); diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/MultifileClassPartCodegen.kt b/compiler/backend/src/org/jetbrains/kotlin/codegen/MultifileClassPartCodegen.kt index fcb01fe0c31..8c8584eb17b 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/MultifileClassPartCodegen.kt +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/MultifileClassPartCodegen.kt @@ -85,7 +85,9 @@ public class MultifileClassPartCodegen( val bindings = v.serializationBindings - val serializer = DescriptorSerializer.createTopLevel(JvmSerializerExtension(bindings, state.typeMapper)) + val serializer = DescriptorSerializer.createTopLevel( + JvmSerializerExtension(bindings, state.typeMapper, state.useTypeTableInSerializer) + ) val packageProto = serializer.packagePartProto(members).build() val av = v.newAnnotation(AsmUtil.asmDescByFqNameWithoutInnerClasses(JvmAnnotationNames.KOTLIN_MULTIFILE_CLASS_PART), true) diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/PackageCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/PackageCodegen.java index 722b1630e05..64998deca0e 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/PackageCodegen.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/PackageCodegen.java @@ -270,7 +270,9 @@ public class PackageCodegen { if (file.isScript()) return; } - DescriptorSerializer serializer = DescriptorSerializer.createTopLevel(new JvmSerializerExtension(bindings, state.getTypeMapper())); + DescriptorSerializer serializer = DescriptorSerializer.createTopLevel(new JvmSerializerExtension( + bindings, state.getTypeMapper(), state.getUseTypeTableInSerializer() + )); Collection packageFragments = Lists.newArrayList(); ContainerUtil.addIfNotNull(packageFragments, packageFragment); ContainerUtil.addIfNotNull(packageFragments, compiledPackageFragment); diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java index 5acbe52546d..974725ea2e8 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java @@ -121,7 +121,9 @@ public class PackagePartCodegen extends MemberCodegen { JvmSerializationBindings bindings = v.getSerializationBindings(); - DescriptorSerializer serializer = DescriptorSerializer.createTopLevel(new JvmSerializerExtension(bindings, state.getTypeMapper())); + DescriptorSerializer serializer = DescriptorSerializer.createTopLevel(new JvmSerializerExtension( + bindings, state.getTypeMapper(), state.getUseTypeTableInSerializer() + )); ProtoBuf.Package packageProto = serializer.packagePartProto(members).build(); AnnotationVisitor av = v.newAnnotation(asmDescByFqNameWithoutInnerClasses(JvmAnnotationNames.KOTLIN_FILE_FACADE), true); diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmSerializerExtension.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmSerializerExtension.java index a0c49b72414..2d5fba77163 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmSerializerExtension.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmSerializerExtension.java @@ -42,11 +42,13 @@ public class JvmSerializerExtension extends SerializerExtension { private final JvmSerializationBindings bindings; private final StringTable stringTable; private final AnnotationSerializer annotationSerializer; + private final boolean useTypeTable; - public JvmSerializerExtension(@NotNull JvmSerializationBindings bindings, @NotNull JetTypeMapper typeMapper) { + public JvmSerializerExtension(@NotNull JvmSerializationBindings bindings, @NotNull JetTypeMapper typeMapper, boolean useTypeTable) { this.bindings = bindings; this.stringTable = new JvmStringTable(typeMapper); this.annotationSerializer = new AnnotationSerializer(stringTable); + this.useTypeTable = useTypeTable; } @NotNull @@ -55,6 +57,11 @@ public class JvmSerializerExtension extends SerializerExtension { return stringTable; } + @Override + public boolean shouldUseTypeTable() { + return useTypeTable; + } + @Override public void serializeClass(@NotNull ClassDescriptor descriptor, @NotNull ProtoBuf.Class.Builder proto) { AnnotationDescriptor annotation = descriptor.getAnnotations().findAnnotation(KotlinBuiltIns.FQ_NAMES.annotation); diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/state/GenerationState.kt b/compiler/backend/src/org/jetbrains/kotlin/codegen/state/GenerationState.kt index 0404d6cf81a..19165f2c78d 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/state/GenerationState.kt +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/state/GenerationState.kt @@ -52,6 +52,7 @@ public class GenerationState @JvmOverloads constructor( public val generateDeclaredClassFilter: GenerationState.GenerateClassFilter = GenerationState.GenerateClassFilter.GENERATE_ALL, disableInline: Boolean = false, disableOptimization: Boolean = false, + public val useTypeTableInSerializer: Boolean = false, public val packageFacadesAsMultifileClasses: Boolean = false, public val diagnostics: DiagnosticSink = DiagnosticSink.DO_NOTHING, public val packagesWithObsoleteParts: Collection = emptySet(), diff --git a/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializer.kt b/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializer.kt index 77fd692930c..c90c35e30c9 100644 --- a/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializer.kt +++ b/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializer.kt @@ -105,7 +105,7 @@ public class BuiltInsSerializer(private val dependOnOldBuiltIns: Boolean) { System.err.println("Could not make directories: " + destDir) } - files.map { it.getPackageFqName() }.toSet().forEach { + files.map { it.packageFqName }.toSet().forEach { fqName -> serializePackage(moduleDescriptor, fqName, destDir) } @@ -117,11 +117,10 @@ public class BuiltInsSerializer(private val dependOnOldBuiltIns: Boolean) { // TODO: perform some kind of validation? At the moment not possible because DescriptorValidator is in compiler-tests // DescriptorValidator.validate(packageView) - val serializer = DescriptorSerializer.createTopLevel(BuiltInsSerializerExtension()) - val classifierDescriptors = DescriptorSerializer.sort(packageView.memberScope.getDescriptors(DescriptorKindFilter.CLASSIFIERS)) - serializeClasses(classifierDescriptors, serializer) { + val extension = BuiltInsSerializerExtension() + serializeClasses(classifierDescriptors, extension) { classDescriptor, classProto -> val stream = ByteArrayOutputStream() classProto.writeTo(stream) @@ -130,13 +129,13 @@ public class BuiltInsSerializer(private val dependOnOldBuiltIns: Boolean) { val packageStream = ByteArrayOutputStream() val fragments = packageView.fragments - val packageProto = serializer.packageProto(fragments).build() ?: error("Package fragments not serialized: $fragments") + val packageProto = DescriptorSerializer.createTopLevel(extension).packageProto(fragments).build() packageProto.writeTo(packageStream) write(destDir, BuiltInsSerializedResourcePaths.getPackageFilePath(fqName), packageStream, BuiltInsSerializedResourcePaths.fallbackPaths.getPackageFilePath(fqName)) val nameStream = ByteArrayOutputStream() - serializer.stringTable.serializeTo(nameStream) + extension.stringTable.serializeTo(nameStream) write(destDir, BuiltInsSerializedResourcePaths.getStringTableFilePath(fqName), nameStream, BuiltInsSerializedResourcePaths.fallbackPaths.getStringTableFilePath(fqName)) } @@ -144,7 +143,7 @@ public class BuiltInsSerializer(private val dependOnOldBuiltIns: Boolean) { private fun write(destDir: File, fileName: String, stream: ByteArrayOutputStream, legacyFileName: String? = null) { totalSize += stream.size() totalFiles++ - File(destDir, fileName).getParentFile().mkdirs() + File(destDir, fileName).parentFile.mkdirs() File(destDir, fileName).writeBytes(stream.toByteArray()) legacyFileName?.let { fileName -> @@ -154,18 +153,18 @@ public class BuiltInsSerializer(private val dependOnOldBuiltIns: Boolean) { private fun serializeClass( classDescriptor: ClassDescriptor, - serializer: DescriptorSerializer, + serializer: BuiltInsSerializerExtension, writeClass: (ClassDescriptor, ProtoBuf.Class) -> Unit ) { - val classProto = serializer.classProto(classDescriptor).build() ?: error("Class not serialized: $classDescriptor") + val classProto = DescriptorSerializer.createTopLevel(serializer).classProto(classDescriptor).build() writeClass(classDescriptor, classProto) - serializeClasses(classDescriptor.getUnsubstitutedInnerClassesScope().getDescriptors(), serializer, writeClass) + serializeClasses(classDescriptor.unsubstitutedInnerClassesScope.getDescriptors(), serializer, writeClass) } private fun serializeClasses( descriptors: Collection, - serializer: DescriptorSerializer, + serializer: BuiltInsSerializerExtension, writeClass: (ClassDescriptor, ProtoBuf.Class) -> Unit ) { for (descriptor in descriptors) { diff --git a/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializerExtension.kt b/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializerExtension.kt index 9db3964a42c..8a4d7441f37 100644 --- a/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializerExtension.kt +++ b/compiler/builtins-serializer/src/org/jetbrains/kotlin/serialization/builtins/BuiltInsSerializerExtension.kt @@ -28,6 +28,8 @@ public class BuiltInsSerializerExtension : SerializerExtension() { override fun getStringTable(): StringTable = stringTable + override fun shouldUseTypeTable(): Boolean = true + override fun serializeClass(descriptor: ClassDescriptor, proto: ProtoBuf.Class.Builder) { for (annotation in descriptor.annotations) { proto.addExtension(BuiltInsProtoBuf.classAnnotation, annotationSerializer.serializeAnnotation(annotation)) diff --git a/compiler/cli/src/org/jetbrains/kotlin/cli/jvm/compiler/KotlinToJVMBytecodeCompiler.java b/compiler/cli/src/org/jetbrains/kotlin/cli/jvm/compiler/KotlinToJVMBytecodeCompiler.java index 13ae807f882..c4808fcce47 100644 --- a/compiler/cli/src/org/jetbrains/kotlin/cli/jvm/compiler/KotlinToJVMBytecodeCompiler.java +++ b/compiler/cli/src/org/jetbrains/kotlin/cli/jvm/compiler/KotlinToJVMBytecodeCompiler.java @@ -398,6 +398,7 @@ public class KotlinToJVMBytecodeCompiler { GenerationState.GenerateClassFilter.GENERATE_ALL, configuration.get(JVMConfigurationKeys.DISABLE_INLINE, false), configuration.get(JVMConfigurationKeys.DISABLE_OPTIMIZATION, false), + /* useTypeTableInSerializer = */ false, configuration.get(JVMConfigurationKeys.PACKAGE_FACADES_AS_MULTIFILE_CLASSES, false), diagnosticHolder, packagesWithObsoleteParts, diff --git a/compiler/light-classes/src/org/jetbrains/kotlin/asJava/KotlinJavaFileStubProvider.java b/compiler/light-classes/src/org/jetbrains/kotlin/asJava/KotlinJavaFileStubProvider.java index b8f9a7e140e..1721e6fb03b 100644 --- a/compiler/light-classes/src/org/jetbrains/kotlin/asJava/KotlinJavaFileStubProvider.java +++ b/compiler/light-classes/src/org/jetbrains/kotlin/asJava/KotlinJavaFileStubProvider.java @@ -429,6 +429,7 @@ public class KotlinJavaFileStubProvider typeParameters; private final SerializerExtension extension; + private final MutableTypeTable typeTable; + private final boolean serializeTypeTableToFunction; - private DescriptorSerializer(Interner typeParameters, SerializerExtension extension) { + private DescriptorSerializer( + @NotNull Interner typeParameters, + @NotNull SerializerExtension extension, + @NotNull MutableTypeTable typeTable, + boolean serializeTypeTableToFunction + ) { this.typeParameters = typeParameters; this.extension = extension; + this.typeTable = typeTable; + this.serializeTypeTableToFunction = serializeTypeTableToFunction; } @NotNull @@ -63,7 +71,12 @@ public class DescriptorSerializer { @NotNull public static DescriptorSerializer createTopLevel(@NotNull SerializerExtension extension) { - return new DescriptorSerializer(new Interner(), extension); + return new DescriptorSerializer(new Interner(), extension, new MutableTypeTable(), false); + } + + @NotNull + public static DescriptorSerializer createForLambda(@NotNull SerializerExtension extension) { + return new DescriptorSerializer(new Interner(), extension, new MutableTypeTable(), true); } @NotNull @@ -77,7 +90,12 @@ public class DescriptorSerializer { // Calculate type parameter ids for the outer class beforehand, as it would've had happened if we were always // serializing outer classes before nested classes. // Otherwise our interner can get wrong ids because we may serialize classes in any order. - DescriptorSerializer serializer = parentSerializer.createChildSerializer(); + DescriptorSerializer serializer = new DescriptorSerializer( + new Interner(parentSerializer.typeParameters), + parentSerializer.extension, + new MutableTypeTable(), + false + ); for (TypeParameterDescriptor typeParameter : descriptor.getTypeConstructor().getParameters()) { serializer.typeParameters.intern(typeParameter); } @@ -86,7 +104,7 @@ public class DescriptorSerializer { @NotNull private DescriptorSerializer createChildSerializer() { - return new DescriptorSerializer(new Interner(typeParameters), extension); + return new DescriptorSerializer(new Interner(typeParameters), extension, typeTable, false); } @NotNull @@ -94,6 +112,10 @@ public class DescriptorSerializer { return extension.getStringTable(); } + private boolean useTypeTable() { + return extension.shouldUseTypeTable(); + } + @NotNull public ProtoBuf.Class.Builder classProto(@NotNull ClassDescriptor classDescriptor) { ProtoBuf.Class.Builder builder = ProtoBuf.Class.newBuilder(); @@ -113,7 +135,12 @@ public class DescriptorSerializer { if (!KotlinBuiltIns.isSpecialClassWithNoSupertypes(classDescriptor)) { // Special classes (Any, Nothing) have no supertypes for (JetType supertype : classDescriptor.getTypeConstructor().getSupertypes()) { - builder.addSupertype(type(supertype)); + if (useTypeTable()) { + builder.addSupertypeId(typeId(supertype)); + } + else { + builder.addSupertype(type(supertype)); + } } } @@ -150,6 +177,11 @@ public class DescriptorSerializer { builder.setCompanionObjectName(getSimpleNameIndex(companionObjectDescriptor.getName())); } + ProtoBuf.TypeTable typeTableProto = typeTable.serialize(); + if (typeTableProto != null) { + builder.setTypeTable(typeTableProto); + } + extension.serializeClass(classDescriptor, builder); return builder; @@ -212,7 +244,12 @@ public class DescriptorSerializer { builder.setName(getSimpleNameIndex(descriptor.getName())); - builder.setReturnType(local.type(descriptor.getType())); + if (useTypeTable()) { + builder.setReturnTypeId(local.typeId(descriptor.getType())); + } + else { + builder.setReturnType(local.type(descriptor.getType())); + } for (TypeParameterDescriptor typeParameterDescriptor : descriptor.getTypeParameters()) { builder.addTypeParameter(local.typeParameter(typeParameterDescriptor)); @@ -220,7 +257,12 @@ public class DescriptorSerializer { ReceiverParameterDescriptor receiverParameter = descriptor.getExtensionReceiverParameter(); if (receiverParameter != null) { - builder.setReceiverType(local.type(receiverParameter.getType())); + if (useTypeTable()) { + builder.setReceiverTypeId(local.typeId(receiverParameter.getType())); + } + else { + builder.setReceiverType(local.type(receiverParameter.getType())); + } } extension.serializeProperty(descriptor, builder); @@ -244,8 +286,14 @@ public class DescriptorSerializer { builder.setName(getSimpleNameIndex(descriptor.getName())); - //noinspection ConstantConditions - builder.setReturnType(local.type(descriptor.getReturnType())); + if (useTypeTable()) { + //noinspection ConstantConditions + builder.setReturnTypeId(local.typeId(descriptor.getReturnType())); + } + else { + //noinspection ConstantConditions + builder.setReturnType(local.type(descriptor.getReturnType())); + } for (TypeParameterDescriptor typeParameterDescriptor : descriptor.getTypeParameters()) { builder.addTypeParameter(local.typeParameter(typeParameterDescriptor)); @@ -253,13 +301,25 @@ public class DescriptorSerializer { ReceiverParameterDescriptor receiverParameter = descriptor.getExtensionReceiverParameter(); if (receiverParameter != null) { - builder.setReceiverType(local.type(receiverParameter.getType())); + if (useTypeTable()) { + builder.setReceiverTypeId(local.typeId(receiverParameter.getType())); + } + else { + builder.setReceiverType(local.type(receiverParameter.getType())); + } } for (ValueParameterDescriptor valueParameterDescriptor : descriptor.getValueParameters()) { builder.addValueParameter(local.valueParameter(valueParameterDescriptor)); } + if (serializeTypeTableToFunction) { + ProtoBuf.TypeTable typeTableProto = typeTable.serialize(); + if (typeTableProto != null) { + builder.setTypeTable(typeTableProto); + } + } + extension.serializeFunction(descriptor, builder); return builder; @@ -305,11 +365,21 @@ public class DescriptorSerializer { builder.setName(getSimpleNameIndex(descriptor.getName())); - builder.setType(type(descriptor.getType())); + if (useTypeTable()) { + builder.setTypeId(typeId(descriptor.getType())); + } + else { + builder.setType(type(descriptor.getType())); + } JetType varargElementType = descriptor.getVarargElementType(); if (varargElementType != null) { - builder.setVarargElementType(type(varargElementType)); + if (useTypeTable()) { + builder.setVarargElementTypeId(typeId(varargElementType)); + } + else { + builder.setVarargElementType(type(varargElementType)); + } } extension.serializeValueParameter(descriptor, builder); @@ -337,7 +407,12 @@ public class DescriptorSerializer { if (upperBounds.size() == 1 && KotlinBuiltIns.isDefaultBound(CollectionsKt.single(upperBounds))) return builder; for (JetType upperBound : upperBounds) { - builder.addUpperBound(type(upperBound)); + if (useTypeTable()) { + builder.addUpperBoundId(typeId(upperBound)); + } + else { + builder.addUpperBound(type(upperBound)); + } } return builder; @@ -355,16 +430,26 @@ public class DescriptorSerializer { throw new IllegalStateException("Unknown variance: " + variance); } + private int typeId(@NotNull JetType type) { + return typeTable.get(type(type)); + } + @NotNull - public ProtoBuf.Type.Builder type(@NotNull JetType type) { + private ProtoBuf.Type.Builder type(@NotNull JetType type) { assert !type.isError() : "Can't serialize error types: " + type; // TODO if (FlexibleTypesKt.isFlexible(type)) { Flexibility flexibility = FlexibleTypesKt.flexibility(type); - return type(flexibility.getLowerBound()) - .setFlexibleTypeCapabilitiesId(getStringTable().getStringIndex(flexibility.getExtraCapabilities().getId())) - .setFlexibleUpperBound(type(flexibility.getUpperBound())); + ProtoBuf.Type.Builder lowerBound = type(flexibility.getLowerBound()); + lowerBound.setFlexibleTypeCapabilitiesId(getStringTable().getStringIndex(flexibility.getExtraCapabilities().getId())); + if (useTypeTable()) { + lowerBound.setFlexibleUpperBoundId(typeId(flexibility.getUpperBound())); + } + else { + lowerBound.setFlexibleUpperBound(type(flexibility.getUpperBound())); + } + return lowerBound; } ProtoBuf.Type.Builder builder = ProtoBuf.Type.newBuilder(); @@ -403,7 +488,13 @@ public class DescriptorSerializer { if (projection != builder.getProjection()) { builder.setProjection(projection); } - builder.setType(type(typeProjection.getType())); + + if (useTypeTable()) { + builder.setTypeId(typeId(typeProjection.getType())); + } + else { + builder.setType(type(typeProjection.getType())); + } } return builder; @@ -443,6 +534,11 @@ public class DescriptorSerializer { } } + ProtoBuf.TypeTable typeTableProto = typeTable.serialize(); + if (typeTableProto != null) { + builder.setTypeTable(typeTableProto); + } + extension.serializePackage(fragments, builder); return builder; @@ -461,6 +557,11 @@ public class DescriptorSerializer { } } + ProtoBuf.TypeTable typeTableProto = typeTable.serialize(); + if (typeTableProto != null) { + builder.setTypeTable(typeTableProto); + } + return builder; } diff --git a/compiler/serialization/src/org/jetbrains/kotlin/serialization/MutableTypeTable.kt b/compiler/serialization/src/org/jetbrains/kotlin/serialization/MutableTypeTable.kt new file mode 100644 index 00000000000..637960dfb33 --- /dev/null +++ b/compiler/serialization/src/org/jetbrains/kotlin/serialization/MutableTypeTable.kt @@ -0,0 +1,45 @@ +/* + * Copyright 2010-2015 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.jetbrains.kotlin.serialization + +import org.jetbrains.kotlin.utils.Interner +import java.util.* + +class MutableTypeTable { + class TypeWrapper(val type: ProtoBuf.Type.Builder) { + // If you'll try to optimize it using structured equals/hashCode, pay attention to extensions present in Type messages + private val bytes: ByteArray = type.build().toByteArray() + private val hashCode: Int = Arrays.hashCode(bytes) + + override fun hashCode() = hashCode + + override fun equals(other: Any?) = other is TypeWrapper && Arrays.equals(bytes, other.bytes) + } + + val interner = Interner() + + operator fun get(type: ProtoBuf.Type.Builder): Int = + interner.intern(TypeWrapper(type)) + + fun serialize(): ProtoBuf.TypeTable? = + if (interner.isEmpty) null + else ProtoBuf.TypeTable.newBuilder().apply { + for (type in interner.allInternedObjects) { + addType(type.type) + } + }.build() +} diff --git a/compiler/serialization/src/org/jetbrains/kotlin/serialization/SerializerExtension.java b/compiler/serialization/src/org/jetbrains/kotlin/serialization/SerializerExtension.java index eff95f2f770..b87be7769c2 100644 --- a/compiler/serialization/src/org/jetbrains/kotlin/serialization/SerializerExtension.java +++ b/compiler/serialization/src/org/jetbrains/kotlin/serialization/SerializerExtension.java @@ -26,6 +26,10 @@ public abstract class SerializerExtension { @NotNull public abstract StringTable getStringTable(); + public boolean shouldUseTypeTable() { + return false; + } + public void serializeClass(@NotNull ClassDescriptor descriptor, @NotNull ProtoBuf.Class.Builder proto) { } diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestUtil.java b/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestUtil.java index c8045f186c7..ad80b82ddd1 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestUtil.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestUtil.java @@ -22,6 +22,7 @@ import kotlin.StringsKt; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import org.jetbrains.kotlin.analyzer.AnalysisResult; +import org.jetbrains.kotlin.cli.jvm.compiler.JvmPackagePartProvider; import org.jetbrains.kotlin.cli.jvm.compiler.KotlinCoreEnvironment; import org.jetbrains.kotlin.cli.jvm.config.JVMConfigurationKeys; import org.jetbrains.kotlin.codegen.forTestCompile.ForTestCompileRuntime; @@ -29,7 +30,6 @@ import org.jetbrains.kotlin.codegen.state.GenerationState; import org.jetbrains.kotlin.config.CompilerConfiguration; import org.jetbrains.kotlin.resolve.AnalyzingUtils; import org.jetbrains.kotlin.resolve.BindingTraceContext; -import org.jetbrains.kotlin.cli.jvm.compiler.JvmPackagePartProvider; import org.jetbrains.kotlin.resolve.lazy.JvmResolveUtil; import org.jetbrains.kotlin.test.JetTestUtils; import org.jetbrains.kotlin.utils.ExceptionUtilsKt; @@ -67,6 +67,7 @@ public class CodegenTestUtil { GenerationState.GenerateClassFilter.GENERATE_ALL, configuration.get(JVMConfigurationKeys.DISABLE_INLINE, false), configuration.get(JVMConfigurationKeys.DISABLE_OPTIMIZATION, false), + /* useTypeTableInSerializer = */ false, configuration.get(JVMConfigurationKeys.PACKAGE_FACADES_AS_MULTIFILE_CLASSES, false), forExtraDiagnostics ); diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/GenerationUtils.java b/compiler/tests/org/jetbrains/kotlin/codegen/GenerationUtils.java index 18c69cee7c1..dc6e4001a34 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/GenerationUtils.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/GenerationUtils.java @@ -49,7 +49,7 @@ public class GenerationUtils { ) { AnalysisResult analysisResult = JvmResolveUtil.analyzeOneFileWithJavaIntegrationAndCheckForErrors(psiFile, new JvmPackagePartProvider(environment)); - return compileFilesGetGenerationState(psiFile.getProject(), analysisResult, Collections.singletonList(psiFile)); + return compileFilesGetGenerationState(psiFile.getProject(), analysisResult, Collections.singletonList(psiFile), false); } @NotNull @@ -63,14 +63,15 @@ public class GenerationUtils { ) { AnalysisResult analysisResult = JvmResolveUtil.analyzeFilesWithJavaIntegrationAndCheckForErrors( project, files, packagePartProvider); - return compileFilesGetGenerationState(project, analysisResult, files); + return compileFilesGetGenerationState(project, analysisResult, files, false); } @NotNull public static GenerationState compileFilesGetGenerationState( @NotNull Project project, @NotNull AnalysisResult analysisResult, - @NotNull List files + @NotNull List files, + boolean useTypeTableInSerializer ) { analysisResult.throwIfError(); GenerationState state = new GenerationState( @@ -78,7 +79,11 @@ public class GenerationUtils { analysisResult.getModuleDescriptor(), analysisResult.getBindingContext(), files, /* disableCallAssertions = */ false, - /* disableParamAssertions = */ false + /* disableParamAssertions = */ false, + GenerationState.GenerateClassFilter.GENERATE_ALL, + /* disableInline = */ false, + /* disableOptimization = */ false, + useTypeTableInSerializer ); KotlinCodegenFacade.compileCorrectFiles(state, CompilationErrorHandler.THROW_EXCEPTION); return state; diff --git a/compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadJavaTest.java b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadJavaTest.java index fb4abdfab26..fd5fec09a4c 100644 --- a/compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadJavaTest.java +++ b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadJavaTest.java @@ -23,6 +23,7 @@ import org.jetbrains.annotations.NotNull; import org.jetbrains.kotlin.analyzer.AnalysisResult; import org.jetbrains.kotlin.cli.jvm.compiler.CliLightClassGenerationSupport; import org.jetbrains.kotlin.cli.jvm.compiler.EnvironmentConfigFiles; +import org.jetbrains.kotlin.cli.jvm.compiler.JvmPackagePartProvider; import org.jetbrains.kotlin.cli.jvm.compiler.KotlinCoreEnvironment; import org.jetbrains.kotlin.cli.jvm.config.JvmContentRootsKt; import org.jetbrains.kotlin.cli.jvm.config.ModuleNameKt; @@ -38,7 +39,6 @@ import org.jetbrains.kotlin.resolve.BindingTrace; import org.jetbrains.kotlin.resolve.DescriptorUtils; import org.jetbrains.kotlin.resolve.TopDownAnalysisMode; import org.jetbrains.kotlin.resolve.jvm.TopDownAnalyzerFacadeForJVM; -import org.jetbrains.kotlin.cli.jvm.compiler.JvmPackagePartProvider; import org.jetbrains.kotlin.resolve.lazy.JvmResolveUtil; import org.jetbrains.kotlin.serialization.deserialization.descriptors.DeserializedClassDescriptor; import org.jetbrains.kotlin.test.ConfigurationKind; @@ -78,7 +78,7 @@ public abstract class AbstractLoadJavaTest extends TestCaseWithTmpdir { File sourcesDir = new File(expectedFileName.replaceFirst("\\.txt$", "")); List kotlinSources = FileUtil.findFilesByMask(Pattern.compile(".+\\.kt"), sourcesDir); - compileKotlinToDirAndGetAnalysisResult(kotlinSources, tmpdir, myTestRootDisposable, ConfigurationKind.JDK_ONLY); + compileKotlinToDirAndGetAnalysisResult(kotlinSources, tmpdir, myTestRootDisposable, ConfigurationKind.JDK_ONLY, false); List javaSources = FileUtil.findFilesByMask(Pattern.compile(".+\\.java"), sourcesDir); Pair binaryPackageAndContext = compileJavaAndLoadTestPackageAndBindingContextFromBinary( @@ -93,18 +93,25 @@ public abstract class AbstractLoadJavaTest extends TestCaseWithTmpdir { } protected void doTestCompiledKotlin(@NotNull String ktFileName) throws Exception { - doTestCompiledKotlin(ktFileName, ConfigurationKind.JDK_ONLY); + doTestCompiledKotlin(ktFileName, ConfigurationKind.JDK_ONLY, false); + } + + protected void doTestCompiledKotlinWithTypeTable(@NotNull String ktFileName) throws Exception { + doTestCompiledKotlin(ktFileName, ConfigurationKind.JDK_ONLY, true); } protected void doTestCompiledKotlinWithStdlib(@NotNull String ktFileName) throws Exception { - doTestCompiledKotlin(ktFileName, ConfigurationKind.ALL); + doTestCompiledKotlin(ktFileName, ConfigurationKind.ALL, false); } - protected void doTestCompiledKotlin(@NotNull String ktFileName, @NotNull ConfigurationKind configurationKind) throws Exception { + private void doTestCompiledKotlin( + @NotNull String ktFileName, @NotNull ConfigurationKind configurationKind, boolean useTypeTableInSerializer + ) throws Exception { File ktFile = new File(ktFileName); File txtFile = new File(ktFileName.replaceFirst("\\.kt$", ".txt")); - AnalysisResult result = compileKotlinToDirAndGetAnalysisResult(Collections.singletonList(ktFile), tmpdir, getTestRootDisposable(), - configurationKind); + AnalysisResult result = compileKotlinToDirAndGetAnalysisResult( + Collections.singletonList(ktFile), tmpdir, getTestRootDisposable(), configurationKind, useTypeTableInSerializer + ); PackageViewDescriptor packageFromSource = result.getModuleDescriptor().getPackage(TEST_PACKAGE_FQNAME); Assert.assertEquals("test", packageFromSource.getName().asString()); diff --git a/compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadKotlinWithTypeTableTest.kt b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadKotlinWithTypeTableTest.kt new file mode 100644 index 00000000000..b071ab3de42 --- /dev/null +++ b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/AbstractLoadKotlinWithTypeTableTest.kt @@ -0,0 +1,23 @@ +/* + * Copyright 2010-2015 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.jetbrains.kotlin.jvm.compiler + +abstract class AbstractLoadKotlinWithTypeTableTest : AbstractLoadJavaTest() { + protected fun doTest(fileName: String) { + doTestCompiledKotlinWithTypeTable(fileName) + } +} diff --git a/compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadDescriptorUtil.java b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadDescriptorUtil.java index 5a330eb099b..24f01667d44 100644 --- a/compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadDescriptorUtil.java +++ b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadDescriptorUtil.java @@ -26,6 +26,7 @@ import org.jetbrains.kotlin.analyzer.AnalysisResult; import org.jetbrains.kotlin.cli.common.output.outputUtils.OutputUtilsKt; import org.jetbrains.kotlin.cli.jvm.compiler.CliLightClassGenerationSupport; import org.jetbrains.kotlin.cli.jvm.compiler.EnvironmentConfigFiles; +import org.jetbrains.kotlin.cli.jvm.compiler.JvmPackagePartProvider; import org.jetbrains.kotlin.cli.jvm.compiler.KotlinCoreEnvironment; import org.jetbrains.kotlin.codegen.GenerationUtils; import org.jetbrains.kotlin.codegen.forTestCompile.ForTestCompileRuntime; @@ -38,7 +39,6 @@ import org.jetbrains.kotlin.name.Name; import org.jetbrains.kotlin.psi.JetFile; import org.jetbrains.kotlin.resolve.BindingContext; import org.jetbrains.kotlin.resolve.BindingTrace; -import org.jetbrains.kotlin.cli.jvm.compiler.JvmPackagePartProvider; import org.jetbrains.kotlin.resolve.lazy.JvmResolveUtil; import org.jetbrains.kotlin.resolve.lazy.LazyResolveTestUtil; import org.jetbrains.kotlin.test.ConfigurationKind; @@ -64,12 +64,15 @@ public final class LoadDescriptorUtil { @NotNull List kotlinFiles, @NotNull File outDir, @NotNull Disposable disposable, - @NotNull ConfigurationKind configurationKind + @NotNull ConfigurationKind configurationKind, + boolean useTypeTableInSerializer ) { JetFilesAndAnalysisResult filesAndResult = JetFilesAndAnalysisResult.createJetFilesAndAnalyze(kotlinFiles, disposable, configurationKind); AnalysisResult result = filesAndResult.getAnalysisResult(); List files = filesAndResult.getJetFiles(); - GenerationState state = GenerationUtils.compileFilesGetGenerationState(files.get(0).getProject(), result, files); + GenerationState state = GenerationUtils.compileFilesGetGenerationState( + files.get(0).getProject(), result, files, useTypeTableInSerializer + ); OutputUtilsKt.writeAllTo(state.getFactory(), outDir); return result; } diff --git a/compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadKotlinWithTypeTableTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadKotlinWithTypeTableTestGenerated.java new file mode 100644 index 00000000000..44e26fa9876 --- /dev/null +++ b/compiler/tests/org/jetbrains/kotlin/jvm/compiler/LoadKotlinWithTypeTableTestGenerated.java @@ -0,0 +1,3088 @@ +/* + * Copyright 2010-2015 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.jetbrains.kotlin.jvm.compiler; + +import com.intellij.testFramework.TestDataPath; +import org.jetbrains.kotlin.test.JUnit3RunnerWithInners; +import org.jetbrains.kotlin.test.JetTestUtils; +import org.jetbrains.kotlin.test.TestMetadata; +import org.junit.runner.RunWith; + +import java.io.File; +import java.util.regex.Pattern; + +/** This class is generated by {@link org.jetbrains.kotlin.generators.tests.TestsPackage}. DO NOT MODIFY MANUALLY */ +@SuppressWarnings("all") +@TestMetadata("compiler/testData/loadJava/compiledKotlin") +@TestDataPath("$PROJECT_ROOT") +@RunWith(JUnit3RunnerWithInners.class) +public class LoadKotlinWithTypeTableTestGenerated extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInCompiledKotlin() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Annotations extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInAnnotations() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("AnnotatedAnnotation.kt") + public void testAnnotatedAnnotation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/AnnotatedAnnotation.kt"); + doTest(fileName); + } + + @TestMetadata("AnnotatedMethod.kt") + public void testAnnotatedMethod() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/AnnotatedMethod.kt"); + doTest(fileName); + } + + @TestMetadata("AnnotationInAnnotationArguments.kt") + public void testAnnotationInAnnotationArguments() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/AnnotationInAnnotationArguments.kt"); + doTest(fileName); + } + + @TestMetadata("EnumArgumentWithCustomToString.kt") + public void testEnumArgumentWithCustomToString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/EnumArgumentWithCustomToString.kt"); + doTest(fileName); + } + + @TestMetadata("MultiDimensionalArrayMethod.kt") + public void testMultiDimensionalArrayMethod() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/MultiDimensionalArrayMethod.kt"); + doTest(fileName); + } + + @TestMetadata("SimpleAnnotation.kt") + public void testSimpleAnnotation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/SimpleAnnotation.kt"); + doTest(fileName); + } + + @TestMetadata("TargetedAnnotation.kt") + public void testTargetedAnnotation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/TargetedAnnotation.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class ClassMembers extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInClassMembers() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations/classMembers"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ClassObjectPropertyField.kt") + public void testClassObjectPropertyField() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/ClassObjectPropertyField.kt"); + doTest(fileName); + } + + @TestMetadata("Constructor.kt") + public void testConstructor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/Constructor.kt"); + doTest(fileName); + } + + @TestMetadata("DelegatedProperty.kt") + public void testDelegatedProperty() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/DelegatedProperty.kt"); + doTest(fileName); + } + + @TestMetadata("EnumArgument.kt") + public void testEnumArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/EnumArgument.kt"); + doTest(fileName); + } + + @TestMetadata("Function.kt") + public void testFunction() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/Function.kt"); + doTest(fileName); + } + + @TestMetadata("Getter.kt") + public void testGetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/Getter.kt"); + doTest(fileName); + } + + @TestMetadata("PropertyField.kt") + public void testPropertyField() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/PropertyField.kt"); + doTest(fileName); + } + + @TestMetadata("Setter.kt") + public void testSetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/Setter.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Classes extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInClasses() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations/classes"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("AnnotationInClassObject.kt") + public void testAnnotationInClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/AnnotationInClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("ClassInClassObject.kt") + public void testClassInClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/ClassInClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObject.kt") + public void testClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/ClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObjectInStaticNestedClass.kt") + public void testClassObjectInStaticNestedClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/ClassObjectInStaticNestedClass.kt"); + doTest(fileName); + } + + @TestMetadata("DataClass.kt") + public void testDataClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/DataClass.kt"); + doTest(fileName); + } + + @TestMetadata("Deprecated.kt") + public void testDeprecated() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/Deprecated.kt"); + doTest(fileName); + } + + @TestMetadata("DollarsInAnnotationName.kt") + public void testDollarsInAnnotationName() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/DollarsInAnnotationName.kt"); + doTest(fileName); + } + + @TestMetadata("EnumArgument.kt") + public void testEnumArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/EnumArgument.kt"); + doTest(fileName); + } + + @TestMetadata("MultipleAnnotations.kt") + public void testMultipleAnnotations() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/MultipleAnnotations.kt"); + doTest(fileName); + } + + @TestMetadata("NestedAnnotation.kt") + public void testNestedAnnotation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/NestedAnnotation.kt"); + doTest(fileName); + } + + @TestMetadata("NestedClass.kt") + public void testNestedClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/NestedClass.kt"); + doTest(fileName); + } + + @TestMetadata("Retention.kt") + public void testRetention() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/Retention.kt"); + doTest(fileName); + } + + @TestMetadata("Simple.kt") + public void testSimple() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/Simple.kt"); + doTest(fileName); + } + + @TestMetadata("WithArgument.kt") + public void testWithArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/WithArgument.kt"); + doTest(fileName); + } + + @TestMetadata("WithMultipleArguments.kt") + public void testWithMultipleArguments() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/classes/WithMultipleArguments.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class PackageMembers extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInPackageMembers() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("DelegatedProperty.kt") + public void testDelegatedProperty() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/DelegatedProperty.kt"); + doTest(fileName); + } + + @TestMetadata("EnumArgument.kt") + public void testEnumArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/EnumArgument.kt"); + doTest(fileName); + } + + @TestMetadata("EnumArrayArgument.kt") + public void testEnumArrayArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/EnumArrayArgument.kt"); + doTest(fileName); + } + + @TestMetadata("Function.kt") + public void testFunction() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/Function.kt"); + doTest(fileName); + } + + @TestMetadata("Getter.kt") + public void testGetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/Getter.kt"); + doTest(fileName); + } + + @TestMetadata("PropertyField.kt") + public void testPropertyField() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/PropertyField.kt"); + doTest(fileName); + } + + @TestMetadata("Setter.kt") + public void testSetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/Setter.kt"); + doTest(fileName); + } + + @TestMetadata("StringArrayArgument.kt") + public void testStringArrayArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/packageMembers/StringArrayArgument.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Parameters extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInParameters() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations/parameters"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("Constructor.kt") + public void testConstructor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/Constructor.kt"); + doTest(fileName); + } + + @TestMetadata("EnumConstructor.kt") + public void testEnumConstructor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/EnumConstructor.kt"); + doTest(fileName); + } + + @TestMetadata("ExtensionFunction.kt") + public void testExtensionFunction() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/ExtensionFunction.kt"); + doTest(fileName); + } + + @TestMetadata("ExtensionFunctionInClass.kt") + public void testExtensionFunctionInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/ExtensionFunctionInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtensionPropertySetter.kt") + public void testExtensionPropertySetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/ExtensionPropertySetter.kt"); + doTest(fileName); + } + + @TestMetadata("FunctionInClass.kt") + public void testFunctionInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/FunctionInClass.kt"); + doTest(fileName); + } + + @TestMetadata("FunctionInTrait.kt") + public void testFunctionInTrait() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/FunctionInTrait.kt"); + doTest(fileName); + } + + @TestMetadata("InnerClassConstructor.kt") + public void testInnerClassConstructor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/InnerClassConstructor.kt"); + doTest(fileName); + } + + @TestMetadata("ManyAnnotations.kt") + public void testManyAnnotations() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/ManyAnnotations.kt"); + doTest(fileName); + } + + @TestMetadata("PropertySetterInClass.kt") + public void testPropertySetterInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/PropertySetterInClass.kt"); + doTest(fileName); + } + + @TestMetadata("TopLevelFunction.kt") + public void testTopLevelFunction() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/TopLevelFunction.kt"); + doTest(fileName); + } + + @TestMetadata("TopLevelPropertySetter.kt") + public void testTopLevelPropertySetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/parameters/TopLevelPropertySetter.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class PropertiesWithoutBackingFields extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInPropertiesWithoutBackingFields() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("Class.kt") + public void testClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/Class.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObject.kt") + public void testClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/ClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("ExtensionsWithSameNameClass.kt") + public void testExtensionsWithSameNameClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/ExtensionsWithSameNameClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtensionsWithSameNamePackage.kt") + public void testExtensionsWithSameNamePackage() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/ExtensionsWithSameNamePackage.kt"); + doTest(fileName); + } + + @TestMetadata("NestedTrait.kt") + public void testNestedTrait() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/NestedTrait.kt"); + doTest(fileName); + } + + @TestMetadata("TopLevel.kt") + public void testTopLevel() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/TopLevel.kt"); + doTest(fileName); + } + + @TestMetadata("Trait.kt") + public void testTrait() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/Trait.kt"); + doTest(fileName); + } + + @TestMetadata("TraitClassObject.kt") + public void testTraitClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/propertiesWithoutBackingFields/TraitClassObject.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations/types") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Types extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInTypes() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations/types"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ReceiverParameter.kt") + public void testReceiverParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/types/ReceiverParameter.kt"); + doTest(fileName); + } + + @TestMetadata("SimpleTypeAnnotation.kt") + public void testSimpleTypeAnnotation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/types/SimpleTypeAnnotation.kt"); + doTest(fileName); + } + + @TestMetadata("SupertypesAndBounds.kt") + public void testSupertypesAndBounds() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/types/SupertypesAndBounds.kt"); + doTest(fileName); + } + + @TestMetadata("TypeAnnotationWithArguments.kt") + public void testTypeAnnotationWithArguments() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/types/TypeAnnotationWithArguments.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/annotations/withUseSiteTarget") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class WithUseSiteTarget extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInWithUseSiteTarget() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/annotations/withUseSiteTarget"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("FieldTarget.kt") + public void testFieldTarget() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/withUseSiteTarget/FieldTarget.kt"); + doTest(fileName); + } + + @TestMetadata("ReceiverTarget.kt") + public void testReceiverTarget() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/annotations/withUseSiteTarget/ReceiverTarget.kt"); + doTest(fileName); + } + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/class") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Class extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInClass() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/class"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("Class.kt") + public void testClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/Class.kt"); + doTest(fileName); + } + + @TestMetadata("ClassInParam.kt") + public void testClassInParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassInParam.kt"); + doTest(fileName); + } + + @TestMetadata("ClassInnerClass.kt") + public void testClassInnerClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassInnerClass.kt"); + doTest(fileName); + } + + @TestMetadata("ClassMemberConflict.kt") + public void testClassMemberConflict() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassMemberConflict.kt"); + doTest(fileName); + } + + @TestMetadata("ClassOutParam.kt") + public void testClassOutParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassOutParam.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParam.kt") + public void testClassParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassParam.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParamReferencesParam.kt") + public void testClassParamReferencesParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassParamReferencesParam.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParamReferencesParam2.kt") + public void testClassParamReferencesParam2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassParamReferencesParam2.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParamReferencesSelf.kt") + public void testClassParamReferencesSelf() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassParamReferencesSelf.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParamUpperClassBound.kt") + public void testClassParamUpperClassBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassParamUpperClassBound.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParamUpperClassInterfaceBound.kt") + public void testClassParamUpperClassInterfaceBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassParamUpperClassInterfaceBound.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParamUpperInterfaceBound.kt") + public void testClassParamUpperInterfaceBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassParamUpperInterfaceBound.kt"); + doTest(fileName); + } + + @TestMetadata("ClassTwoParams.kt") + public void testClassTwoParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassTwoParams.kt"); + doTest(fileName); + } + + @TestMetadata("ClassTwoParams2.kt") + public void testClassTwoParams2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/ClassTwoParams2.kt"); + doTest(fileName); + } + + @TestMetadata("EnumWithGenericConstructorParameter.kt") + public void testEnumWithGenericConstructorParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/EnumWithGenericConstructorParameter.kt"); + doTest(fileName); + } + + @TestMetadata("EnumWithPrimitiveConstructorParameter.kt") + public void testEnumWithPrimitiveConstructorParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/EnumWithPrimitiveConstructorParameter.kt"); + doTest(fileName); + } + + @TestMetadata("InheritClassSimple.kt") + public void testInheritClassSimple() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/InheritClassSimple.kt"); + doTest(fileName); + } + + @TestMetadata("InheritClassWithParam.kt") + public void testInheritClassWithParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/InheritClassWithParam.kt"); + doTest(fileName); + } + + @TestMetadata("InheritSubstitutedMethod.kt") + public void testInheritSubstitutedMethod() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/InheritSubstitutedMethod.kt"); + doTest(fileName); + } + + @TestMetadata("InheritTraitWithFunctionParam.kt") + public void testInheritTraitWithFunctionParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/InheritTraitWithFunctionParam.kt"); + doTest(fileName); + } + + @TestMetadata("InheritTraitWithParam.kt") + public void testInheritTraitWithParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/InheritTraitWithParam.kt"); + doTest(fileName); + } + + @TestMetadata("InnerClassExtendInnerClass.kt") + public void testInnerClassExtendInnerClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/InnerClassExtendInnerClass.kt"); + doTest(fileName); + } + + @TestMetadata("InnerGenericClass.kt") + public void testInnerGenericClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/InnerGenericClass.kt"); + doTest(fileName); + } + + @TestMetadata("NamedObject.kt") + public void testNamedObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NamedObject.kt"); + doTest(fileName); + } + + @TestMetadata("NamedObjectInClass.kt") + public void testNamedObjectInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NamedObjectInClass.kt"); + doTest(fileName); + } + + @TestMetadata("NamedObjectInClassObject.kt") + public void testNamedObjectInClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NamedObjectInClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("NamedObjectInNamedObject.kt") + public void testNamedObjectInNamedObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NamedObjectInNamedObject.kt"); + doTest(fileName); + } + + @TestMetadata("NamedObjectWithAnotherTopLevelProperty.kt") + public void testNamedObjectWithAnotherTopLevelProperty() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NamedObjectWithAnotherTopLevelProperty.kt"); + doTest(fileName); + } + + @TestMetadata("NestedClass.kt") + public void testNestedClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NestedClass.kt"); + doTest(fileName); + } + + @TestMetadata("NestedClassExtendNestedClass.kt") + public void testNestedClassExtendNestedClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NestedClassExtendNestedClass.kt"); + doTest(fileName); + } + + @TestMetadata("NestedGenericClass.kt") + public void testNestedGenericClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/NestedGenericClass.kt"); + doTest(fileName); + } + + @TestMetadata("RecursiveGeneric.kt") + public void testRecursiveGeneric() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/RecursiveGeneric.kt"); + doTest(fileName); + } + + @TestMetadata("SingleAbstractMethod.kt") + public void testSingleAbstractMethod() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/SingleAbstractMethod.kt"); + doTest(fileName); + } + + @TestMetadata("Trait.kt") + public void testTrait() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/Trait.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/class/javaBean") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class JavaBean extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInJavaBean() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/class/javaBean"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("DifferentGetterAndSetter.kt") + public void testDifferentGetterAndSetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/javaBean/DifferentGetterAndSetter.kt"); + doTest(fileName); + } + + @TestMetadata("JavaBeanAbstractGetter.kt") + public void testJavaBeanAbstractGetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/javaBean/JavaBeanAbstractGetter.kt"); + doTest(fileName); + } + + @TestMetadata("JavaBeanVal.kt") + public void testJavaBeanVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/javaBean/JavaBeanVal.kt"); + doTest(fileName); + } + + @TestMetadata("JavaBeanVar.kt") + public void testJavaBeanVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/javaBean/JavaBeanVar.kt"); + doTest(fileName); + } + + @TestMetadata("JavaBeanVarOfGenericType.kt") + public void testJavaBeanVarOfGenericType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/javaBean/JavaBeanVarOfGenericType.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSetters.kt") + public void testTwoSetters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/class/javaBean/TwoSetters.kt"); + doTest(fileName); + } + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/classFun") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class ClassFun extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInClassFun() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/classFun"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ClassInParamUsedInFun.kt") + public void testClassInParamUsedInFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classFun/ClassInParamUsedInFun.kt"); + doTest(fileName); + } + + @TestMetadata("ClassParamUsedInFun.kt") + public void testClassParamUsedInFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classFun/ClassParamUsedInFun.kt"); + doTest(fileName); + } + + @TestMetadata("FunDelegationToTraitImpl.kt") + public void testFunDelegationToTraitImpl() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classFun/FunDelegationToTraitImpl.kt"); + doTest(fileName); + } + + @TestMetadata("FunInParamSuper.kt") + public void testFunInParamSuper() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classFun/FunInParamSuper.kt"); + doTest(fileName); + } + + @TestMetadata("TraitFinalFun.kt") + public void testTraitFinalFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classFun/TraitFinalFun.kt"); + doTest(fileName); + } + + @TestMetadata("TraitOpenFun.kt") + public void testTraitOpenFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classFun/TraitOpenFun.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/classObject") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class ClassObject extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInClassObject() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/classObject"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ClassObjectDeclaresVal.kt") + public void testClassObjectDeclaresVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/ClassObjectDeclaresVal.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObjectDeclaresVar.kt") + public void testClassObjectDeclaresVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/ClassObjectDeclaresVar.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObjectDefaultVisibility.kt") + public void testClassObjectDefaultVisibility() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/ClassObjectDefaultVisibility.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObjectExplicitVisibility.kt") + public void testClassObjectExplicitVisibility() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/ClassObjectExplicitVisibility.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObjectExtendsTrait.kt") + public void testClassObjectExtendsTrait() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/ClassObjectExtendsTrait.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObjectExtendsTraitWithTP.kt") + public void testClassObjectExtendsTraitWithTP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/ClassObjectExtendsTraitWithTP.kt"); + doTest(fileName); + } + + @TestMetadata("classObjectInClassStaticFields.kt") + public void testClassObjectInClassStaticFields() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/classObjectInClassStaticFields.kt"); + doTest(fileName); + } + + @TestMetadata("classObjectInTraitStaticFields.kt") + public void testClassObjectInTraitStaticFields() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/classObjectInTraitStaticFields.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObjectPropertyInClass.kt") + public void testClassObjectPropertyInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/ClassObjectPropertyInClass.kt"); + doTest(fileName); + } + + @TestMetadata("Delegation.kt") + public void testDelegation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/Delegation.kt"); + doTest(fileName); + } + + @TestMetadata("InnerClassInClassObject.kt") + public void testInnerClassInClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/InnerClassInClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("NamedClassObject.kt") + public void testNamedClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/NamedClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("SimpleClassObject.kt") + public void testSimpleClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/classObject/SimpleClassObject.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/constructor") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Constructor extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInConstructor() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/constructor"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("Constructor0.kt") + public void testConstructor0() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/Constructor0.kt"); + doTest(fileName); + } + + @TestMetadata("Constructor1.kt") + public void testConstructor1() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/Constructor1.kt"); + doTest(fileName); + } + + @TestMetadata("Constructor1WithParamDefaultValue.kt") + public void testConstructor1WithParamDefaultValue() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/Constructor1WithParamDefaultValue.kt"); + doTest(fileName); + } + + @TestMetadata("Constructor2WithOneParamDefaultValue.kt") + public void testConstructor2WithOneParamDefaultValue() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/Constructor2WithOneParamDefaultValue.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorCollectionParameter.kt") + public void testConstructorCollectionParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorCollectionParameter.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorGenericDeep.kt") + public void testConstructorGenericDeep() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorGenericDeep.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorGenericSimple.kt") + public void testConstructorGenericSimple() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorGenericSimple.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorGenericUpperBound.kt") + public void testConstructorGenericUpperBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorGenericUpperBound.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithTwoDefArgs.kt") + public void testConstructorWithTwoDefArgs() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorWithTwoDefArgs.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithTwoTypeParameters.kt") + public void testConstructorWithTwoTypeParameters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorWithTwoTypeParameters.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithTwoTypeParametersAndOneIntValueParameter.kt") + public void testConstructorWithTwoTypeParametersAndOneIntValueParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorWithTwoTypeParametersAndOneIntValueParameter.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithTwoTypeParametersAndOnePValueParameter.kt") + public void testConstructorWithTwoTypeParametersAndOnePValueParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorWithTwoTypeParametersAndOnePValueParameter.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithTypeParameter.kt") + public void testConstructorWithTypeParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorWithTypeParameter.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithTypeParametersEAndOnePValueParameter.kt") + public void testConstructorWithTypeParametersEAndOnePValueParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/ConstructorWithTypeParametersEAndOnePValueParameter.kt"); + doTest(fileName); + } + + @TestMetadata("InnerClassConstructorWithDefArgs.kt") + public void testInnerClassConstructorWithDefArgs() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/InnerClassConstructorWithDefArgs.kt"); + doTest(fileName); + } + + @TestMetadata("PrivateConstructor1WithParamDefaultValue.kt") + public void testPrivateConstructor1WithParamDefaultValue() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/PrivateConstructor1WithParamDefaultValue.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/constructor/vararg") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Vararg extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInVararg() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/constructor/vararg"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ConstructorNonLastVararg.kt") + public void testConstructorNonLastVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/vararg/ConstructorNonLastVararg.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorVararg.kt") + public void testConstructorVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/constructor/vararg/ConstructorVararg.kt"); + doTest(fileName); + } + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/dataClass") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class DataClass extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInDataClass() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/dataClass"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("MixedComponents.kt") + public void testMixedComponents() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/dataClass/MixedComponents.kt"); + doTest(fileName); + } + + @TestMetadata("NoComponents.kt") + public void testNoComponents() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/dataClass/NoComponents.kt"); + doTest(fileName); + } + + @TestMetadata("OneVal.kt") + public void testOneVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/dataClass/OneVal.kt"); + doTest(fileName); + } + + @TestMetadata("ParamNameSameToField.kt") + public void testParamNameSameToField() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/dataClass/ParamNameSameToField.kt"); + doTest(fileName); + } + + @TestMetadata("TwoVals.kt") + public void testTwoVals() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/dataClass/TwoVals.kt"); + doTest(fileName); + } + + @TestMetadata("TwoVars.kt") + public void testTwoVars() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/dataClass/TwoVars.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/enum") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Enum extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInEnum() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/enum"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("enumVisibility.kt") + public void testEnumVisibility() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/enum/enumVisibility.kt"); + doTest(fileName); + } + + @TestMetadata("enumWithConstuctor.kt") + public void testEnumWithConstuctor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/enum/enumWithConstuctor.kt"); + doTest(fileName); + } + + @TestMetadata("enumWithInnerClasses.kt") + public void testEnumWithInnerClasses() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/enum/enumWithInnerClasses.kt"); + doTest(fileName); + } + + @TestMetadata("innerEnum.kt") + public void testInnerEnum() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/enum/innerEnum.kt"); + doTest(fileName); + } + + @TestMetadata("innerEnumExistingClassObject.kt") + public void testInnerEnumExistingClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/enum/innerEnumExistingClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("simpleEnum.kt") + public void testSimpleEnum() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/enum/simpleEnum.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class FromLoadJava extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInFromLoadJava() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ArrayTypeVariance.kt") + public void testArrayTypeVariance() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ArrayTypeVariance.kt"); + doTest(fileName); + } + + @TestMetadata("ClassDoesNotOverrideMethod.kt") + public void testClassDoesNotOverrideMethod() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassDoesNotOverrideMethod.kt"); + doTest(fileName); + } + + @TestMetadata("ClassObject.kt") + public void testClassObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassObject.kt"); + doTest(fileName); + } + + @TestMetadata("classObjectAnnotation.kt") + public void testClassObjectAnnotation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/classObjectAnnotation.kt"); + doTest(fileName); + } + + @TestMetadata("ClassWithConstVal.kt") + public void testClassWithConstVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassWithConstVal.kt"); + doTest(fileName); + } + + @TestMetadata("ClassWithTypeP.kt") + public void testClassWithTypeP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassWithTypeP.kt"); + doTest(fileName); + } + + @TestMetadata("ClassWithTypePExtendsIterableP.kt") + public void testClassWithTypePExtendsIterableP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassWithTypePExtendsIterableP.kt"); + doTest(fileName); + } + + @TestMetadata("ClassWithTypePP.kt") + public void testClassWithTypePP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassWithTypePP.kt"); + doTest(fileName); + } + + @TestMetadata("ClassWithTypePRefNext.kt") + public void testClassWithTypePRefNext() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassWithTypePRefNext.kt"); + doTest(fileName); + } + + @TestMetadata("ClassWithTypePRefSelf.kt") + public void testClassWithTypePRefSelf() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassWithTypePRefSelf.kt"); + doTest(fileName); + } + + @TestMetadata("ClassWithTypePRefSelfAndClass.kt") + public void testClassWithTypePRefSelfAndClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/ClassWithTypePRefSelfAndClass.kt"); + doTest(fileName); + } + + @TestMetadata("enum.kt") + public void testEnum() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/enum.kt"); + doTest(fileName); + } + + @TestMetadata("FieldAsVar.kt") + public void testFieldAsVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/FieldAsVar.kt"); + doTest(fileName); + } + + @TestMetadata("FieldOfArrayType.kt") + public void testFieldOfArrayType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/FieldOfArrayType.kt"); + doTest(fileName); + } + + @TestMetadata("FinalFieldAsVal.kt") + public void testFinalFieldAsVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/FinalFieldAsVal.kt"); + doTest(fileName); + } + + @TestMetadata("genericFunction.kt") + public void testGenericFunction() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/genericFunction.kt"); + doTest(fileName); + } + + @TestMetadata("InheritMethodsDifferentReturnTypes.kt") + public void testInheritMethodsDifferentReturnTypes() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/InheritMethodsDifferentReturnTypes.kt"); + doTest(fileName); + } + + @TestMetadata("InheritMethodsDifferentReturnTypesGeneric.kt") + public void testInheritMethodsDifferentReturnTypesGeneric() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/InheritMethodsDifferentReturnTypesGeneric.kt"); + doTest(fileName); + } + + @TestMetadata("InnerClass.kt") + public void testInnerClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/InnerClass.kt"); + doTest(fileName); + } + + @TestMetadata("MethodTypePOneUpperBound.kt") + public void testMethodTypePOneUpperBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/MethodTypePOneUpperBound.kt"); + doTest(fileName); + } + + @TestMetadata("MethodTypePTwoUpperBounds.kt") + public void testMethodTypePTwoUpperBounds() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/MethodTypePTwoUpperBounds.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithTypeP.kt") + public void testMethodWithTypeP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/MethodWithTypeP.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithTypePP.kt") + public void testMethodWithTypePP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/MethodWithTypePP.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithTypePRefClassP.kt") + public void testMethodWithTypePRefClassP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/MethodWithTypePRefClassP.kt"); + doTest(fileName); + } + + @TestMetadata("MethosWithPRefTP.kt") + public void testMethosWithPRefTP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/MethosWithPRefTP.kt"); + doTest(fileName); + } + + @TestMetadata("MyException.kt") + public void testMyException() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/MyException.kt"); + doTest(fileName); + } + + @TestMetadata("NestedClass.kt") + public void testNestedClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/NestedClass.kt"); + doTest(fileName); + } + + @TestMetadata("objectInClass.kt") + public void testObjectInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/objectInClass.kt"); + doTest(fileName); + } + + @TestMetadata("objectMembers.kt") + public void testObjectMembers() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/objectMembers.kt"); + doTest(fileName); + } + + @TestMetadata("packageLevelObject.kt") + public void testPackageLevelObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/packageLevelObject.kt"); + doTest(fileName); + } + + @TestMetadata("RemoveRedundantProjectionKind.kt") + public void testRemoveRedundantProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/RemoveRedundantProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("Simple.kt") + public void testSimple() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/Simple.kt"); + doTest(fileName); + } + + @TestMetadata("TwoFields.kt") + public void testTwoFields() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/TwoFields.kt"); + doTest(fileName); + } + + @TestMetadata("UnboundWildcard.kt") + public void testUnboundWildcard() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/UnboundWildcard.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class KotlinSignature extends AbstractLoadKotlinWithTypeTableTest { + @TestMetadata("AllBoundsInWhen.kt") + public void testAllBoundsInWhen() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/AllBoundsInWhen.kt"); + doTest(fileName); + } + + public void testAllFilesPresentInKotlinSignature() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ArrayType.kt") + public void testArrayType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/ArrayType.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithNewTypeParams.kt") + public void testConstructorWithNewTypeParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/ConstructorWithNewTypeParams.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithParentTypeParams.kt") + public void testConstructorWithParentTypeParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/ConstructorWithParentTypeParams.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithSeveralParams.kt") + public void testConstructorWithSeveralParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/ConstructorWithSeveralParams.kt"); + doTest(fileName); + } + + @TestMetadata("ConstructorWithoutParams.kt") + public void testConstructorWithoutParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/ConstructorWithoutParams.kt"); + doTest(fileName); + } + + @TestMetadata("CustomProjectionKind.kt") + public void testCustomProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/CustomProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithFunctionTypes.kt") + public void testMethodWithFunctionTypes() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/MethodWithFunctionTypes.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithGenerics.kt") + public void testMethodWithGenerics() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/MethodWithGenerics.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithMappedClasses.kt") + public void testMethodWithMappedClasses() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/MethodWithMappedClasses.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithTypeParameters.kt") + public void testMethodWithTypeParameters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/MethodWithTypeParameters.kt"); + doTest(fileName); + } + + @TestMetadata("MethodWithVararg.kt") + public void testMethodWithVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/MethodWithVararg.kt"); + doTest(fileName); + } + + @TestMetadata("PropertyArrayTypes.kt") + public void testPropertyArrayTypes() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/PropertyArrayTypes.kt"); + doTest(fileName); + } + + @TestMetadata("PropertyComplexTypes.kt") + public void testPropertyComplexTypes() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/PropertyComplexTypes.kt"); + doTest(fileName); + } + + @TestMetadata("PropertySimpleType.kt") + public void testPropertySimpleType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/PropertySimpleType.kt"); + doTest(fileName); + } + + @TestMetadata("StarProjection.kt") + public void testStarProjection() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/StarProjection.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Error extends AbstractLoadKotlinWithTypeTableTest { + @TestMetadata("AddingNullability.kt") + public void testAddingNullability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/AddingNullability.kt"); + doTest(fileName); + } + + public void testAllFilesPresentInError() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ConflictingProjectionKind.kt") + public void testConflictingProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/ConflictingProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("ExplicitFieldGettersAndSetters.kt") + public void testExplicitFieldGettersAndSetters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/ExplicitFieldGettersAndSetters.kt"); + doTest(fileName); + } + + @TestMetadata("ExtraUpperBound.kt") + public void testExtraUpperBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/ExtraUpperBound.kt"); + doTest(fileName); + } + + @TestMetadata("MissingUpperBound.kt") + public void testMissingUpperBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/MissingUpperBound.kt"); + doTest(fileName); + } + + @TestMetadata("NoFieldTypeRef.kt") + public void testNoFieldTypeRef() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/NoFieldTypeRef.kt"); + doTest(fileName); + } + + @TestMetadata("NotVarargReplacedWithVararg.kt") + public void testNotVarargReplacedWithVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/NotVarargReplacedWithVararg.kt"); + doTest(fileName); + } + + @TestMetadata("RedundantProjectionKind.kt") + public void testRedundantProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/RedundantProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("ReturnTypeMissing.kt") + public void testReturnTypeMissing() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/ReturnTypeMissing.kt"); + doTest(fileName); + } + + @TestMetadata("SyntaxError.kt") + public void testSyntaxError() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/SyntaxError.kt"); + doTest(fileName); + } + + @TestMetadata("SyntaxErrorInFieldAnnotation.kt") + public void testSyntaxErrorInFieldAnnotation() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/SyntaxErrorInFieldAnnotation.kt"); + doTest(fileName); + } + + @TestMetadata("VarargReplacedWithNotVararg.kt") + public void testVarargReplacedWithNotVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/VarargReplacedWithNotVararg.kt"); + doTest(fileName); + } + + @TestMetadata("WrongFieldInitializer.kt") + public void testWrongFieldInitializer() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongFieldInitializer.kt"); + doTest(fileName); + } + + @TestMetadata("WrongFieldMutability.kt") + public void testWrongFieldMutability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongFieldMutability.kt"); + doTest(fileName); + } + + @TestMetadata("WrongFieldName.kt") + public void testWrongFieldName() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongFieldName.kt"); + doTest(fileName); + } + + @TestMetadata("WrongMethodName.kt") + public void testWrongMethodName() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongMethodName.kt"); + doTest(fileName); + } + + @TestMetadata("WrongProjectionKind.kt") + public void testWrongProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("WrongReturnTypeStructure.kt") + public void testWrongReturnTypeStructure() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongReturnTypeStructure.kt"); + doTest(fileName); + } + + @TestMetadata("WrongTypeName1.kt") + public void testWrongTypeName1() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongTypeName1.kt"); + doTest(fileName); + } + + @TestMetadata("WrongTypeName2.kt") + public void testWrongTypeName2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongTypeName2.kt"); + doTest(fileName); + } + + @TestMetadata("WrongTypeName3.kt") + public void testWrongTypeName3() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongTypeName3.kt"); + doTest(fileName); + } + + @TestMetadata("WrongTypeParameterBoundStructure1.kt") + public void testWrongTypeParameterBoundStructure1() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongTypeParameterBoundStructure1.kt"); + doTest(fileName); + } + + @TestMetadata("WrongTypeParameterBoundStructure2.kt") + public void testWrongTypeParameterBoundStructure2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongTypeParameterBoundStructure2.kt"); + doTest(fileName); + } + + @TestMetadata("WrongTypeParametersCount.kt") + public void testWrongTypeParametersCount() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongTypeParametersCount.kt"); + doTest(fileName); + } + + @TestMetadata("WrongValueParameterStructure1.kt") + public void testWrongValueParameterStructure1() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongValueParameterStructure1.kt"); + doTest(fileName); + } + + @TestMetadata("WrongValueParameterStructure2.kt") + public void testWrongValueParameterStructure2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongValueParameterStructure2.kt"); + doTest(fileName); + } + + @TestMetadata("WrongValueParametersCount.kt") + public void testWrongValueParametersCount() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/error/WrongValueParametersCount.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Propagation extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInPropagation() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("PropagateTypeArgumentNullable.kt") + public void testPropagateTypeArgumentNullable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/PropagateTypeArgumentNullable.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Parameter extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInParameter() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ChangeProjectionKind1.kt") + public void testChangeProjectionKind1() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/ChangeProjectionKind1.kt"); + doTest(fileName); + } + + @TestMetadata("ChangeProjectionKind2.kt") + public void testChangeProjectionKind2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/ChangeProjectionKind2.kt"); + doTest(fileName); + } + + @TestMetadata("DeeplySubstitutedClassParameter.kt") + public void testDeeplySubstitutedClassParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter.kt"); + doTest(fileName); + } + + @TestMetadata("DeeplySubstitutedClassParameter2.kt") + public void testDeeplySubstitutedClassParameter2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter2.kt"); + doTest(fileName); + } + + @TestMetadata("InheritMutability.kt") + public void testInheritMutability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritMutability.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNotVararg.kt") + public void testInheritNotVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritNotVararg.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNotVarargInteger.kt") + public void testInheritNotVarargInteger() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritNotVarargInteger.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNotVarargNotNull.kt") + public void testInheritNotVarargNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritNotVarargNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNotVarargPrimitive.kt") + public void testInheritNotVarargPrimitive() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritNotVarargPrimitive.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNullability.kt") + public void testInheritNullability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritNullability.kt"); + doTest(fileName); + } + + @TestMetadata("InheritProjectionKind.kt") + public void testInheritProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("InheritReadOnliness.kt") + public void testInheritReadOnliness() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritReadOnliness.kt"); + doTest(fileName); + } + + @TestMetadata("InheritVararg.kt") + public void testInheritVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritVararg.kt"); + doTest(fileName); + } + + @TestMetadata("InheritVarargInteger.kt") + public void testInheritVarargInteger() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritVarargInteger.kt"); + doTest(fileName); + } + + @TestMetadata("InheritVarargNotNull.kt") + public void testInheritVarargNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritVarargNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("InheritVarargPrimitive.kt") + public void testInheritVarargPrimitive() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/InheritVarargPrimitive.kt"); + doTest(fileName); + } + + @TestMetadata("Kt3302.kt") + public void testKt3302() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/Kt3302.kt"); + doTest(fileName); + } + + @TestMetadata("MutableToReadOnly.kt") + public void testMutableToReadOnly() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/MutableToReadOnly.kt"); + doTest(fileName); + } + + @TestMetadata("NotNullToNullable.kt") + public void testNotNullToNullable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/NotNullToNullable.kt"); + doTest(fileName); + } + + @TestMetadata("NullableToNotNull.kt") + public void testNullableToNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/NullableToNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("NullableToNotNullKotlinSignature.kt") + public void testNullableToNotNullKotlinSignature() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/NullableToNotNullKotlinSignature.kt"); + doTest(fileName); + } + + @TestMetadata("OverrideWithErasedParameter.kt") + public void testOverrideWithErasedParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/OverrideWithErasedParameter.kt"); + doTest(fileName); + } + + @TestMetadata("ReadOnlyToMutable.kt") + public void testReadOnlyToMutable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/ReadOnlyToMutable.kt"); + doTest(fileName); + } + + @TestMetadata("SubclassFromGenericAndNot.kt") + public void testSubclassFromGenericAndNot() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/SubclassFromGenericAndNot.kt"); + doTest(fileName); + } + + @TestMetadata("SubstitutedClassParameter.kt") + public void testSubstitutedClassParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/SubstitutedClassParameter.kt"); + doTest(fileName); + } + + @TestMetadata("SubstitutedClassParameters.kt") + public void testSubstitutedClassParameters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/parameter/SubstitutedClassParameters.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Return extends AbstractLoadKotlinWithTypeTableTest { + @TestMetadata("AddNotNullJavaSubtype.kt") + public void testAddNotNullJavaSubtype() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/AddNotNullJavaSubtype.kt"); + doTest(fileName); + } + + @TestMetadata("AddNotNullSameJavaType.kt") + public void testAddNotNullSameJavaType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/AddNotNullSameJavaType.kt"); + doTest(fileName); + } + + @TestMetadata("AddNullabilityJavaSubtype.kt") + public void testAddNullabilityJavaSubtype() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/AddNullabilityJavaSubtype.kt"); + doTest(fileName); + } + + @TestMetadata("AddNullabilitySameGenericType1.kt") + public void testAddNullabilitySameGenericType1() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/AddNullabilitySameGenericType1.kt"); + doTest(fileName); + } + + @TestMetadata("AddNullabilitySameGenericType2.kt") + public void testAddNullabilitySameGenericType2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/AddNullabilitySameGenericType2.kt"); + doTest(fileName); + } + + @TestMetadata("AddNullabilitySameJavaType.kt") + public void testAddNullabilitySameJavaType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/AddNullabilitySameJavaType.kt"); + doTest(fileName); + } + + public void testAllFilesPresentInReturn() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("CantMakeImmutableInSubclass.kt") + public void testCantMakeImmutableInSubclass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/CantMakeImmutableInSubclass.kt"); + doTest(fileName); + } + + @TestMetadata("DeeplySubstitutedClassParameter.kt") + public void testDeeplySubstitutedClassParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter.kt"); + doTest(fileName); + } + + @TestMetadata("DeeplySubstitutedClassParameter2.kt") + public void testDeeplySubstitutedClassParameter2() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter2.kt"); + doTest(fileName); + } + + @TestMetadata("HalfSubstitutedTypeParameters.kt") + public void testHalfSubstitutedTypeParameters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/HalfSubstitutedTypeParameters.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNullabilityGenericSubclassSimple.kt") + public void testInheritNullabilityGenericSubclassSimple() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritNullabilityGenericSubclassSimple.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNullabilityJavaSubtype.kt") + public void testInheritNullabilityJavaSubtype() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritNullabilityJavaSubtype.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNullabilitySameGenericType.kt") + public void testInheritNullabilitySameGenericType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritNullabilitySameGenericType.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNullabilitySameJavaType.kt") + public void testInheritNullabilitySameJavaType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritNullabilitySameJavaType.kt"); + doTest(fileName); + } + + @TestMetadata("InheritProjectionKind.kt") + public void testInheritProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("InheritReadOnlinessOfArgument.kt") + public void testInheritReadOnlinessOfArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritReadOnlinessOfArgument.kt"); + doTest(fileName); + } + + @TestMetadata("InheritReadOnlinessSameClass.kt") + public void testInheritReadOnlinessSameClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritReadOnlinessSameClass.kt"); + doTest(fileName); + } + + @TestMetadata("InheritReadOnlinessSubclass.kt") + public void testInheritReadOnlinessSubclass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/InheritReadOnlinessSubclass.kt"); + doTest(fileName); + } + + @TestMetadata("SameProjectionKind.kt") + public void testSameProjectionKind() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/SameProjectionKind.kt"); + doTest(fileName); + } + + @TestMetadata("SubclassFromGenericAndNot.kt") + public void testSubclassFromGenericAndNot() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/SubclassFromGenericAndNot.kt"); + doTest(fileName); + } + + @TestMetadata("SubclassOfCollection.kt") + public void testSubclassOfCollection() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/SubclassOfCollection.kt"); + doTest(fileName); + } + + @TestMetadata("SubclassOfMapEntry.kt") + public void testSubclassOfMapEntry() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/SubclassOfMapEntry.kt"); + doTest(fileName); + } + + @TestMetadata("SubstitutedClassParameter.kt") + public void testSubstitutedClassParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/SubstitutedClassParameter.kt"); + doTest(fileName); + } + + @TestMetadata("SubstitutedClassParameters.kt") + public void testSubstitutedClassParameters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/SubstitutedClassParameters.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclassesConflictingProjectionKinds.kt") + public void testTwoSuperclassesConflictingProjectionKinds() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TwoSuperclassesConflictingProjectionKinds.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclassesInvariantAndCovariantInferMutability.kt") + public void testTwoSuperclassesInvariantAndCovariantInferMutability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TwoSuperclassesInvariantAndCovariantInferMutability.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclassesInvariantAndCovariantInferNullability.kt") + public void testTwoSuperclassesInvariantAndCovariantInferNullability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TwoSuperclassesInvariantAndCovariantInferNullability.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclassesMutableAndNot.kt") + public void testTwoSuperclassesMutableAndNot() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TwoSuperclassesMutableAndNot.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclassesReturnJavaSubtype.kt") + public void testTwoSuperclassesReturnJavaSubtype() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TwoSuperclassesReturnJavaSubtype.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclassesReturnSameJavaType.kt") + public void testTwoSuperclassesReturnSameJavaType() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TwoSuperclassesReturnSameJavaType.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclassesSupplementNotNull.kt") + public void testTwoSuperclassesSupplementNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TwoSuperclassesSupplementNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("TypeParamOfClass.kt") + public void testTypeParamOfClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TypeParamOfClass.kt"); + doTest(fileName); + } + + @TestMetadata("TypeParamOfClassSubstituted.kt") + public void testTypeParamOfClassSubstituted() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TypeParamOfClassSubstituted.kt"); + doTest(fileName); + } + + @TestMetadata("TypeParamOfFun.kt") + public void testTypeParamOfFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/return/TypeParamOfFun.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class TypeParameter extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInTypeParameter() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("InheritMutability.kt") + public void testInheritMutability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/InheritMutability.kt"); + doTest(fileName); + } + + @TestMetadata("InheritNullability.kt") + public void testInheritNullability() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/InheritNullability.kt"); + doTest(fileName); + } + + @TestMetadata("InheritReadOnliness.kt") + public void testInheritReadOnliness() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/InheritReadOnliness.kt"); + doTest(fileName); + } + + @TestMetadata("TwoBounds.kt") + public void testTwoBounds() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/TwoBounds.kt"); + doTest(fileName); + } + + @TestMetadata("TwoSuperclasses.kt") + public void testTwoSuperclasses() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/TwoSuperclasses.kt"); + doTest(fileName); + } + + @TestMetadata("TwoTypeParameters.kt") + public void testTwoTypeParameters() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/TwoTypeParameters.kt"); + doTest(fileName); + } + + @TestMetadata("UseParameterAsUpperBound.kt") + public void testUseParameterAsUpperBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/UseParameterAsUpperBound.kt"); + doTest(fileName); + } + + @TestMetadata("UseParameterInUpperBound.kt") + public void testUseParameterInUpperBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBound.kt"); + doTest(fileName); + } + + @TestMetadata("UseParameterInUpperBoundWithKotlinSignature.kt") + public void testUseParameterInUpperBoundWithKotlinSignature() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBoundWithKotlinSignature.kt"); + doTest(fileName); + } + } + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/library") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Library extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInLibrary() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/library"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("LoadIterable.kt") + public void testLoadIterable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/library/LoadIterable.kt"); + doTest(fileName); + } + + @TestMetadata("LoadIterator.kt") + public void testLoadIterator() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/library/LoadIterator.kt"); + doTest(fileName); + } + + @TestMetadata("Max.kt") + public void testMax() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/library/Max.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/modality") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Modality extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInModality() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/modality"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ModalityOfFakeOverrides.kt") + public void testModalityOfFakeOverrides() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/modality/ModalityOfFakeOverrides.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/notNull") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class NotNull extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInNotNull() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fromLoadJava/notNull"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("NotNullField.kt") + public void testNotNullField() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/notNull/NotNullField.kt"); + doTest(fileName); + } + + @TestMetadata("NotNullIntArray.kt") + public void testNotNullIntArray() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/notNull/NotNullIntArray.kt"); + doTest(fileName); + } + + @TestMetadata("NotNullMethod.kt") + public void testNotNullMethod() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/notNull/NotNullMethod.kt"); + doTest(fileName); + } + + @TestMetadata("NotNullObjectArray.kt") + public void testNotNullObjectArray() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/notNull/NotNullObjectArray.kt"); + doTest(fileName); + } + + @TestMetadata("NotNullParameter.kt") + public void testNotNullParameter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fromLoadJava/notNull/NotNullParameter.kt"); + doTest(fileName); + } + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fun") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Fun extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInFun() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fun"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("Assert.kt") + public void testAssert() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/Assert.kt"); + doTest(fileName); + } + + @TestMetadata("DeclaredMemberOverridesDelegated.kt") + public void testDeclaredMemberOverridesDelegated() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/DeclaredMemberOverridesDelegated.kt"); + doTest(fileName); + } + + @TestMetadata("InfixKeyword.kt") + public void testInfixKeyword() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/InfixKeyword.kt"); + doTest(fileName); + } + + @TestMetadata("InheritMethodsDifferentReturnTypesAndVisibilities.kt") + public void testInheritMethodsDifferentReturnTypesAndVisibilities() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/InheritMethodsDifferentReturnTypesAndVisibilities.kt"); + doTest(fileName); + } + + @TestMetadata("InheritValAndVar.kt") + public void testInheritValAndVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/InheritValAndVar.kt"); + doTest(fileName); + } + + @TestMetadata("InheritValsDifferentTypes.kt") + public void testInheritValsDifferentTypes() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/InheritValsDifferentTypes.kt"); + doTest(fileName); + } + + @TestMetadata("NoSamAdapter.kt") + public void testNoSamAdapter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/NoSamAdapter.kt"); + doTest(fileName); + } + + @TestMetadata("NoSamConstructor.kt") + public void testNoSamConstructor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/NoSamConstructor.kt"); + doTest(fileName); + } + + @TestMetadata("OperatorKeyword.kt") + public void testOperatorKeyword() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/OperatorKeyword.kt"); + doTest(fileName); + } + + @TestMetadata("PropagateDeepSubclass.kt") + public void testPropagateDeepSubclass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/PropagateDeepSubclass.kt"); + doTest(fileName); + } + + @TestMetadata("PropagateSubclassOfComparable.kt") + public void testPropagateSubclassOfComparable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/PropagateSubclassOfComparable.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class GenericWithTypeVariables extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInGenericWithTypeVariables() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("FunGenericParam.kt") + public void testFunGenericParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunGenericParam.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamParam.kt") + public void testFunParamParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamParam.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamParamErased.kt") + public void testFunParamParamErased() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamParamErased.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamReferencesParam.kt") + public void testFunParamReferencesParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamReferencesParam.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamTwoUpperBounds.kt") + public void testFunParamTwoUpperBounds() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamTwoUpperBounds.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamUpperClassBound.kt") + public void testFunParamUpperClassBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamUpperClassBound.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamUpperClassInterfaceBound.kt") + public void testFunParamUpperClassInterfaceBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamUpperClassInterfaceBound.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamUpperInterfaceBound.kt") + public void testFunParamUpperInterfaceBound() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamUpperInterfaceBound.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamVaragParam.kt") + public void testFunParamVaragParam() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunParamVaragParam.kt"); + doTest(fileName); + } + + @TestMetadata("FunTwoTypeParams.kt") + public void testFunTwoTypeParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithTypeVariables/FunTwoTypeParams.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithoutTypeVariables") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class GenericWithoutTypeVariables extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInGenericWithoutTypeVariables() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fun/genericWithoutTypeVariables"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("FunClassParamNotNull.kt") + public void testFunClassParamNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithoutTypeVariables/FunClassParamNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("FunClassParamNullable.kt") + public void testFunClassParamNullable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithoutTypeVariables/FunClassParamNullable.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamNullable.kt") + public void testFunParamNullable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithoutTypeVariables/FunParamNullable.kt"); + doTest(fileName); + } + + @TestMetadata("ReturnTypeClassParamNotNull.kt") + public void testReturnTypeClassParamNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithoutTypeVariables/ReturnTypeClassParamNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("ReturnTypeClassParamNullable.kt") + public void testReturnTypeClassParamNullable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/genericWithoutTypeVariables/ReturnTypeClassParamNullable.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class NonGeneric extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInNonGeneric() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ClassFun.kt") + public void testClassFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ClassFun.kt"); + doTest(fileName); + } + + @TestMetadata("ClassFunGetFoo.kt") + public void testClassFunGetFoo() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ClassFunGetFoo.kt"); + doTest(fileName); + } + + @TestMetadata("ClassFunGetFooSetFoo.kt") + public void testClassFunGetFooSetFoo() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ClassFunGetFooSetFoo.kt"); + doTest(fileName); + } + + @TestMetadata("ClassFunSetFoo.kt") + public void testClassFunSetFoo() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ClassFunSetFoo.kt"); + doTest(fileName); + } + + @TestMetadata("ExtFun.kt") + public void testExtFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ExtFun.kt"); + doTest(fileName); + } + + @TestMetadata("ExtFunInClass.kt") + public void testExtFunInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ExtFunInClass.kt"); + doTest(fileName); + } + + @TestMetadata("FunDefaultArg.kt") + public void testFunDefaultArg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/FunDefaultArg.kt"); + doTest(fileName); + } + + @TestMetadata("FunParamNotNull.kt") + public void testFunParamNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/FunParamNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("FunVarargInt.kt") + public void testFunVarargInt() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/FunVarargInt.kt"); + doTest(fileName); + } + + @TestMetadata("FunVarargInteger.kt") + public void testFunVarargInteger() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/FunVarargInteger.kt"); + doTest(fileName); + } + + @TestMetadata("ModifierAbstract.kt") + public void testModifierAbstract() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ModifierAbstract.kt"); + doTest(fileName); + } + + @TestMetadata("ModifierOpen.kt") + public void testModifierOpen() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ModifierOpen.kt"); + doTest(fileName); + } + + @TestMetadata("NsFun.kt") + public void testNsFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/NsFun.kt"); + doTest(fileName); + } + + @TestMetadata("NsFunGetFoo.kt") + public void testNsFunGetFoo() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/NsFunGetFoo.kt"); + doTest(fileName); + } + + @TestMetadata("ReturnTypeNotNull.kt") + public void testReturnTypeNotNull() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ReturnTypeNotNull.kt"); + doTest(fileName); + } + + @TestMetadata("ReturnTypeNullable.kt") + public void testReturnTypeNullable() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/nonGeneric/ReturnTypeNullable.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/fun/vararg") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Vararg extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInVararg() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/fun/vararg"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("nonLastVararg.kt") + public void testNonLastVararg() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/vararg/nonLastVararg.kt"); + doTest(fileName); + } + + @TestMetadata("VarargInt.kt") + public void testVarargInt() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/vararg/VarargInt.kt"); + doTest(fileName); + } + + @TestMetadata("VarargString.kt") + public void testVarargString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/fun/vararg/VarargString.kt"); + doTest(fileName); + } + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/inline") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Inline extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInInline() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/inline"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("inlineFunction.kt") + public void testInlineFunction() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/inline/inlineFunction.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/memberOrder") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class MemberOrder extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInMemberOrder() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/memberOrder"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("callablesNameClash.kt") + public void testCallablesNameClash() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/memberOrder/callablesNameClash.kt"); + doTest(fileName); + } + + @TestMetadata("enumEntries.kt") + public void testEnumEntries() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/memberOrder/enumEntries.kt"); + doTest(fileName); + } + + @TestMetadata("extensionMembers.kt") + public void testExtensionMembers() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/memberOrder/extensionMembers.kt"); + doTest(fileName); + } + + @TestMetadata("extensionPropertiesNameClash.kt") + public void testExtensionPropertiesNameClash() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/memberOrder/extensionPropertiesNameClash.kt"); + doTest(fileName); + } + + @TestMetadata("innerClasses.kt") + public void testInnerClasses() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/memberOrder/innerClasses.kt"); + doTest(fileName); + } + + @TestMetadata("topLevelCallables.kt") + public void testTopLevelCallables() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/memberOrder/topLevelCallables.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/nested") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Nested extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInNested() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/nested"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("deepInnerGeneric.kt") + public void testDeepInnerGeneric() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/nested/deepInnerGeneric.kt"); + doTest(fileName); + } + + @TestMetadata("innerClassReferencesOuterTP.kt") + public void testInnerClassReferencesOuterTP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/nested/innerClassReferencesOuterTP.kt"); + doTest(fileName); + } + + @TestMetadata("membersReferenceOuterTP.kt") + public void testMembersReferenceOuterTP() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/nested/membersReferenceOuterTP.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/platformTypes") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class PlatformTypes extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInPlatformTypes() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/platformTypes"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("notnullTypeArgument.kt") + public void testNotnullTypeArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/platformTypes/notnullTypeArgument.kt"); + doTest(fileName); + } + + @TestMetadata("nullableTypeArgument.kt") + public void testNullableTypeArgument() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/platformTypes/nullableTypeArgument.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/prop") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Prop extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInProp() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/prop"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ClassVal.kt") + public void testClassVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ClassVal.kt"); + doTest(fileName); + } + + @TestMetadata("ClassValAbstract.kt") + public void testClassValAbstract() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ClassValAbstract.kt"); + doTest(fileName); + } + + @TestMetadata("ClassVar.kt") + public void testClassVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ClassVar.kt"); + doTest(fileName); + } + + @TestMetadata("CollectionSize.kt") + public void testCollectionSize() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/CollectionSize.kt"); + doTest(fileName); + } + + @TestMetadata("Const.kt") + public void testConst() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/Const.kt"); + doTest(fileName); + } + + @TestMetadata("Constants.kt") + public void testConstants() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/Constants.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValClass.kt") + public void testExtValClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValInClass.kt") + public void testExtValInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValInt.kt") + public void testExtValInt() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValInt.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValIntCharSequence.kt") + public void testExtValIntCharSequence() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValIntCharSequence.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValIntCharSequenceQ.kt") + public void testExtValIntCharSequenceQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValIntCharSequenceQ.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValIntListQOfIntInClass.kt") + public void testExtValIntListQOfIntInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValIntListQOfIntInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValIntTInClass.kt") + public void testExtValIntTInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValIntTInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValIntTQInClass.kt") + public void testExtValIntTQInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValIntTQInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValTIntInClass.kt") + public void testExtValTIntInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtValTIntInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarClass.kt") + public void testExtVarClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarInClass.kt") + public void testExtVarInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarInt.kt") + public void testExtVarInt() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarInt.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarIntTInClass.kt") + public void testExtVarIntTInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarIntTInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarIntTQInClass.kt") + public void testExtVarIntTQInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarIntTQInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarMapPQInt.kt") + public void testExtVarMapPQInt() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarMapPQInt.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarTIntInClass.kt") + public void testExtVarTIntInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarTIntInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarTQIntInClass.kt") + public void testExtVarTQIntInClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarTQIntInClass.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarl.kt") + public void testExtVarl() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/ExtVarl.kt"); + doTest(fileName); + } + + @TestMetadata("NsVal.kt") + public void testNsVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/NsVal.kt"); + doTest(fileName); + } + + @TestMetadata("NsVar.kt") + public void testNsVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/NsVar.kt"); + doTest(fileName); + } + + @TestMetadata("OverrideClassVal.kt") + public void testOverrideClassVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/OverrideClassVal.kt"); + doTest(fileName); + } + + @TestMetadata("OverrideTraitVal.kt") + public void testOverrideTraitVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/OverrideTraitVal.kt"); + doTest(fileName); + } + + @TestMetadata("PropFromSuperclass.kt") + public void testPropFromSuperclass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/PropFromSuperclass.kt"); + doTest(fileName); + } + + @TestMetadata("TraitFinalVar.kt") + public void testTraitFinalVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/TraitFinalVar.kt"); + doTest(fileName); + } + + @TestMetadata("TraitOpenVal.kt") + public void testTraitOpenVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/TraitOpenVal.kt"); + doTest(fileName); + } + + @TestMetadata("VarDelegationToTraitImpl.kt") + public void testVarDelegationToTraitImpl() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/VarDelegationToTraitImpl.kt"); + doTest(fileName); + } + + @TestMetadata("VarWithDelegated.kt") + public void testVarWithDelegated() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/VarWithDelegated.kt"); + doTest(fileName); + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class DefaultAccessors extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInDefaultAccessors() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("ClassVal.kt") + public void testClassVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassVal.kt"); + doTest(fileName); + } + + @TestMetadata("ClassValParams.kt") + public void testClassValParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassValParams.kt"); + doTest(fileName); + } + + @TestMetadata("ClassValWithGet.kt") + public void testClassValWithGet() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassValWithGet.kt"); + doTest(fileName); + } + + @TestMetadata("ClassVar.kt") + public void testClassVar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassVar.kt"); + doTest(fileName); + } + + @TestMetadata("ClassVarModality.kt") + public void testClassVarModality() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassVarModality.kt"); + doTest(fileName); + } + + @TestMetadata("ClassVarParams.kt") + public void testClassVarParams() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassVarParams.kt"); + doTest(fileName); + } + + @TestMetadata("ClassVarWithGet.kt") + public void testClassVarWithGet() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassVarWithGet.kt"); + doTest(fileName); + } + + @TestMetadata("ClassVarWithSet.kt") + public void testClassVarWithSet() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ClassVarWithSet.kt"); + doTest(fileName); + } + + @TestMetadata("ExtValLong.kt") + public void testExtValLong() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ExtValLong.kt"); + doTest(fileName); + } + + @TestMetadata("ExtVarLong.kt") + public void testExtVarLong() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/prop/defaultAccessors/ExtVarLong.kt"); + doTest(fileName); + } + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/type") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Type extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInType() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/type"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("Any.kt") + public void testAny() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/Any.kt"); + doTest(fileName); + } + + @TestMetadata("AnyQ.kt") + public void testAnyQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/AnyQ.kt"); + doTest(fileName); + } + + @TestMetadata("ArrayOfInNumber.kt") + public void testArrayOfInNumber() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ArrayOfInNumber.kt"); + doTest(fileName); + } + + @TestMetadata("ArrayOfInt.kt") + public void testArrayOfInt() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ArrayOfInt.kt"); + doTest(fileName); + } + + @TestMetadata("ArrayOfInteger.kt") + public void testArrayOfInteger() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ArrayOfInteger.kt"); + doTest(fileName); + } + + @TestMetadata("ArrayOfOutNumber.kt") + public void testArrayOfOutNumber() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ArrayOfOutNumber.kt"); + doTest(fileName); + } + + @TestMetadata("ArrayOfOutT.kt") + public void testArrayOfOutT() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ArrayOfOutT.kt"); + doTest(fileName); + } + + @TestMetadata("ArrayOfString.kt") + public void testArrayOfString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ArrayOfString.kt"); + doTest(fileName); + } + + @TestMetadata("Function1IntString.kt") + public void testFunction1IntString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/Function1IntString.kt"); + doTest(fileName); + } + + @TestMetadata("Int.kt") + public void testInt() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/Int.kt"); + doTest(fileName); + } + + @TestMetadata("IntArray.kt") + public void testIntArray() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/IntArray.kt"); + doTest(fileName); + } + + @TestMetadata("IntQ.kt") + public void testIntQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/IntQ.kt"); + doTest(fileName); + } + + @TestMetadata("jlInteger.kt") + public void testJlInteger() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/jlInteger.kt"); + doTest(fileName); + } + + @TestMetadata("jlIntegerQ.kt") + public void testJlIntegerQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/jlIntegerQ.kt"); + doTest(fileName); + } + + @TestMetadata("jlNumber.kt") + public void testJlNumber() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/jlNumber.kt"); + doTest(fileName); + } + + @TestMetadata("jlObject.kt") + public void testJlObject() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/jlObject.kt"); + doTest(fileName); + } + + @TestMetadata("jlObjectQ.kt") + public void testJlObjectQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/jlObjectQ.kt"); + doTest(fileName); + } + + @TestMetadata("jlString.kt") + public void testJlString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/jlString.kt"); + doTest(fileName); + } + + @TestMetadata("jlStringQ.kt") + public void testJlStringQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/jlStringQ.kt"); + doTest(fileName); + } + + @TestMetadata("ListOfAny.kt") + public void testListOfAny() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ListOfAny.kt"); + doTest(fileName); + } + + @TestMetadata("ListOfAnyQ.kt") + public void testListOfAnyQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ListOfAnyQ.kt"); + doTest(fileName); + } + + @TestMetadata("ListOfStar.kt") + public void testListOfStar() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ListOfStar.kt"); + doTest(fileName); + } + + @TestMetadata("ListOfString.kt") + public void testListOfString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ListOfString.kt"); + doTest(fileName); + } + + @TestMetadata("ListOfjlString.kt") + public void testListOfjlString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/ListOfjlString.kt"); + doTest(fileName); + } + + @TestMetadata("Nothing.kt") + public void testNothing() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/Nothing.kt"); + doTest(fileName); + } + + @TestMetadata("NothingQ.kt") + public void testNothingQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/NothingQ.kt"); + doTest(fileName); + } + + @TestMetadata("platform.kt") + public void testPlatform() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/platform.kt"); + doTest(fileName); + } + + @TestMetadata("String.kt") + public void testString() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/String.kt"); + doTest(fileName); + } + + @TestMetadata("StringQ.kt") + public void testStringQ() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/StringQ.kt"); + doTest(fileName); + } + + @TestMetadata("Unit.kt") + public void testUnit() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/type/Unit.kt"); + doTest(fileName); + } + } + + @TestMetadata("compiler/testData/loadJava/compiledKotlin/visibility") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Visibility extends AbstractLoadKotlinWithTypeTableTest { + public void testAllFilesPresentInVisibility() throws Exception { + JetTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/loadJava/compiledKotlin/visibility"), Pattern.compile("^(.+)\\.kt$"), true); + } + + @TestMetadata("InternalClass.kt") + public void testInternalClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/InternalClass.kt"); + doTest(fileName); + } + + @TestMetadata("InternalConstructor.kt") + public void testInternalConstructor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/InternalConstructor.kt"); + doTest(fileName); + } + + @TestMetadata("InternalTopLevelMembers.kt") + public void testInternalTopLevelMembers() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/InternalTopLevelMembers.kt"); + doTest(fileName); + } + + @TestMetadata("PrivateClass.kt") + public void testPrivateClass() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/PrivateClass.kt"); + doTest(fileName); + } + + @TestMetadata("PrivateClassMembers.kt") + public void testPrivateClassMembers() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/PrivateClassMembers.kt"); + doTest(fileName); + } + + @TestMetadata("PrivateToThis.kt") + public void testPrivateToThis() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/PrivateToThis.kt"); + doTest(fileName); + } + + @TestMetadata("PrivateTopLevelFun.kt") + public void testPrivateTopLevelFun() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/PrivateTopLevelFun.kt"); + doTest(fileName); + } + + @TestMetadata("PrivateTopLevelVal.kt") + public void testPrivateTopLevelVal() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/PrivateTopLevelVal.kt"); + doTest(fileName); + } + + @TestMetadata("PropertyInConstructor.kt") + public void testPropertyInConstructor() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/PropertyInConstructor.kt"); + doTest(fileName); + } + + @TestMetadata("PropertyInConstructorExplicitVisibility.kt") + public void testPropertyInConstructorExplicitVisibility() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/PropertyInConstructorExplicitVisibility.kt"); + doTest(fileName); + } + + @TestMetadata("TopLevelVarWithPrivateSetter.kt") + public void testTopLevelVarWithPrivateSetter() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/loadJava/compiledKotlin/visibility/TopLevelVarWithPrivateSetter.kt"); + doTest(fileName); + } + } +} diff --git a/compiler/tests/org/jetbrains/kotlin/serialization/AbstractLocalClassProtoTest.kt b/compiler/tests/org/jetbrains/kotlin/serialization/AbstractLocalClassProtoTest.kt index f1899b6a4fc..53f59d8be6a 100644 --- a/compiler/tests/org/jetbrains/kotlin/serialization/AbstractLocalClassProtoTest.kt +++ b/compiler/tests/org/jetbrains/kotlin/serialization/AbstractLocalClassProtoTest.kt @@ -38,7 +38,7 @@ import java.net.URLClassLoader public abstract class AbstractLocalClassProtoTest : TestCaseWithTmpdir() { protected fun doTest(filename: String) { val source = File(filename) - LoadDescriptorUtil.compileKotlinToDirAndGetAnalysisResult(listOf(source), tmpdir, testRootDisposable, ConfigurationKind.ALL) + LoadDescriptorUtil.compileKotlinToDirAndGetAnalysisResult(listOf(source), tmpdir, testRootDisposable, ConfigurationKind.ALL, false) val classNameSuffix = InTextDirectivesUtils.findStringWithPrefixes(source.readText(), "// CLASS_NAME_SUFFIX: ") ?: error("CLASS_NAME_SUFFIX directive not found in test data") diff --git a/compiler/tests/org/jetbrains/kotlin/test/JetTestUtils.java b/compiler/tests/org/jetbrains/kotlin/test/JetTestUtils.java index bdb7d3bba10..55f7c21ac74 100644 --- a/compiler/tests/org/jetbrains/kotlin/test/JetTestUtils.java +++ b/compiler/tests/org/jetbrains/kotlin/test/JetTestUtils.java @@ -521,7 +521,7 @@ public class JetTestUtils { @Nullable File javaErrorFile ) throws IOException { if (!ktFiles.isEmpty()) { - compileKotlinToDirAndGetAnalysisResult(ktFiles, outDir, disposable, ALL); + compileKotlinToDirAndGetAnalysisResult(ktFiles, outDir, disposable, ALL, false); } else { boolean mkdirs = outDir.mkdirs(); diff --git a/compiler/util/src/org/jetbrains/kotlin/utils/Interner.java b/compiler/util/src/org/jetbrains/kotlin/utils/Interner.java index 610e1c785d5..a98f40f2990 100644 --- a/compiler/util/src/org/jetbrains/kotlin/utils/Interner.java +++ b/compiler/util/src/org/jetbrains/kotlin/utils/Interner.java @@ -68,4 +68,8 @@ public final class Interner { } }); } + + public boolean isEmpty() { + return interned.isEmpty() && (parent == null || parent.isEmpty()); + } } diff --git a/generators/src/org/jetbrains/kotlin/generators/tests/GenerateTests.kt b/generators/src/org/jetbrains/kotlin/generators/tests/GenerateTests.kt index 299645fcf9c..eaf863a8388 100644 --- a/generators/src/org/jetbrains/kotlin/generators/tests/GenerateTests.kt +++ b/generators/src/org/jetbrains/kotlin/generators/tests/GenerateTests.kt @@ -260,6 +260,10 @@ fun main(args: Array) { model("loadJava/sourceJava", extension = "java", testMethod = "doTestSourceJava") } + testClass() { + model("loadJava/compiledKotlin") + } + testClass() { model("loadJava/compiledKotlin") model("loadJava/compiledJava", extension = "java", excludeDirs = listOf("sam", "kotlinSignature/propagation")) diff --git a/idea/src/org/jetbrains/kotlin/idea/internal/KotlinBytecodeToolWindow.java b/idea/src/org/jetbrains/kotlin/idea/internal/KotlinBytecodeToolWindow.java index 93ba4ad4f9c..2acc20dd105 100644 --- a/idea/src/org/jetbrains/kotlin/idea/internal/KotlinBytecodeToolWindow.java +++ b/idea/src/org/jetbrains/kotlin/idea/internal/KotlinBytecodeToolWindow.java @@ -239,6 +239,7 @@ public class KotlinBytecodeToolWindow extends JPanel implements Disposable { generateClassFilter, !enableInline, !enableOptimization, + /*useTypeTableInSerializer=*/false, /*packageFacadesAsMultifileClasses=*/false, sink); KotlinCodegenFacade.compileCorrectFiles(state, CompilationErrorHandler.THROW_EXCEPTION);