Generate even more FE10 analysis API tests
This commit is contained in:
+90
@@ -0,0 +1,90 @@
|
||||
/*
|
||||
* Copyright 2010-2021 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
|
||||
package org.jetbrains.kotlin.analysis.api.fe10.test.cases.generated.cases.components.psiTypeProvider;
|
||||
|
||||
import com.intellij.testFramework.TestDataPath;
|
||||
import org.jetbrains.kotlin.test.util.KtTestUtil;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.kotlin.analysis.api.fe10.test.configurator.AnalysisApiFe10TestConfiguratorFactory;
|
||||
import org.jetbrains.kotlin.analysis.test.framework.test.configurators.AnalysisApiTestConfiguratorFactoryData;
|
||||
import org.jetbrains.kotlin.analysis.test.framework.test.configurators.AnalysisApiTestConfigurator;
|
||||
import org.jetbrains.kotlin.analysis.test.framework.test.configurators.TestModuleKind;
|
||||
import org.jetbrains.kotlin.analysis.test.framework.test.configurators.FrontendKind;
|
||||
import org.jetbrains.kotlin.analysis.test.framework.test.configurators.AnalysisSessionMode;
|
||||
import org.jetbrains.kotlin.analysis.test.framework.test.configurators.AnalysisApiMode;
|
||||
import org.jetbrains.kotlin.analysis.api.impl.base.test.cases.components.psiTypeProvider.AbstractAnalysisApiPsiTypeProviderTest;
|
||||
import org.jetbrains.kotlin.test.TestMetadata;
|
||||
import org.junit.jupiter.api.Nested;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
/** This class is generated by {@link GenerateNewCompilerTests.kt}. DO NOT MODIFY MANUALLY */
|
||||
@SuppressWarnings("all")
|
||||
@TestMetadata("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
public class Fe10IdeNormalAnalysisSourceModuleAnalysisApiPsiTypeProviderTestGenerated extends AbstractAnalysisApiPsiTypeProviderTest {
|
||||
@NotNull
|
||||
@Override
|
||||
public AnalysisApiTestConfigurator getConfigurator() {
|
||||
return AnalysisApiFe10TestConfiguratorFactory.INSTANCE.createConfigurator(
|
||||
new AnalysisApiTestConfiguratorFactoryData(
|
||||
FrontendKind.Fe10,
|
||||
TestModuleKind.Source,
|
||||
AnalysisSessionMode.Normal,
|
||||
AnalysisApiMode.Ide
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testAllFilesPresentInForDeclaration() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration"), Pattern.compile("^(.+)\\.kt$"), null, true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("anonymousObject_exposedAsReturnValue.kt")
|
||||
public void testAnonymousObject_exposedAsReturnValue() throws Exception {
|
||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration/anonymousObject_exposedAsReturnValue.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localClass_exposedAsReturnValue.kt")
|
||||
public void testLocalClass_exposedAsReturnValue() throws Exception {
|
||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration/localClass_exposedAsReturnValue.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localClass_exposedAsReturnValue_privateFunction.kt")
|
||||
public void testLocalClass_exposedAsReturnValue_privateFunction() throws Exception {
|
||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration/localClass_exposedAsReturnValue_privateFunction.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localClass_localFunctionInSameScope.kt")
|
||||
public void testLocalClass_localFunctionInSameScope() throws Exception {
|
||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration/localClass_localFunctionInSameScope.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localClass_localPropertyInSameScope.kt")
|
||||
public void testLocalClass_localPropertyInSameScope() throws Exception {
|
||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration/localClass_localPropertyInSameScope.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localClass_localPropertyInSampeScope_functionalType.kt")
|
||||
public void testLocalClass_localPropertyInSampeScope_functionalType() throws Exception {
|
||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration/localClass_localPropertyInSampeScope_functionalType.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("localClass_memberFunction.kt")
|
||||
public void testLocalClass_memberFunction() throws Exception {
|
||||
runTest("analysis/analysis-api/testData/components/psiTypeProvider/psiType/forDeclaration/localClass_memberFunction.kt");
|
||||
}
|
||||
}
|
||||
+1452
File diff suppressed because it is too large
Load Diff
+2
-3
@@ -49,8 +49,7 @@ import org.jetbrains.kotlin.generators.util.TestGeneratorUtil
|
||||
internal fun AnalysisApiTestGroup.generateAnalysisApiTests() {
|
||||
test(
|
||||
AbstractReferenceResolveTest::class,
|
||||
filter = frontendIs(FrontendKind.Fir) and
|
||||
testModuleKindIs(TestModuleKind.Source, TestModuleKind.LibrarySource) and
|
||||
filter = testModuleKindIs(TestModuleKind.Source, TestModuleKind.LibrarySource) and
|
||||
analysisApiModeIs(AnalysisApiMode.Ide, AnalysisApiMode.Standalone),
|
||||
) { data ->
|
||||
when (data.moduleKind) {
|
||||
@@ -196,7 +195,7 @@ private fun AnalysisApiTestGroup.generateAnalysisApiComponentsTests() {
|
||||
}
|
||||
|
||||
component("psiTypeProvider") {
|
||||
test(AbstractAnalysisApiPsiTypeProviderTest::class, filter = frontendIs(FrontendKind.Fir)) {
|
||||
test(AbstractAnalysisApiPsiTypeProviderTest::class) {
|
||||
model("psiType/forDeclaration")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user