From 294ec3905b64cd66c083fdc69f6c5e41b702b831 Mon Sep 17 00:00:00 2001 From: Nikita Bobko Date: Tue, 8 Jun 2021 19:07:56 +0200 Subject: [PATCH] [cleanup] Remove unused AbstractSymbolByFqNameTest --- .../api/AbstractSymbolByFqNameTest.kt | 43 ------------------- 1 file changed, 43 deletions(-) delete mode 100644 idea/idea-frontend-fir/tests/org/jetbrains/kotlin/idea/fir/frontend/api/AbstractSymbolByFqNameTest.kt diff --git a/idea/idea-frontend-fir/tests/org/jetbrains/kotlin/idea/fir/frontend/api/AbstractSymbolByFqNameTest.kt b/idea/idea-frontend-fir/tests/org/jetbrains/kotlin/idea/fir/frontend/api/AbstractSymbolByFqNameTest.kt deleted file mode 100644 index 2c75cd40c21..00000000000 --- a/idea/idea-frontend-fir/tests/org/jetbrains/kotlin/idea/fir/frontend/api/AbstractSymbolByFqNameTest.kt +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright 2010-2020 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.idea.fir.frontend.api - -import org.jetbrains.kotlin.idea.fir.executeOnPooledThreadInReadAction -import org.jetbrains.kotlin.idea.frontend.api.KtAnalysisSession -import org.jetbrains.kotlin.idea.frontend.api.analyse -import org.jetbrains.kotlin.idea.frontend.api.symbols.DebugSymbolRenderer -import org.jetbrains.kotlin.idea.frontend.api.symbols.KtSymbol -import org.jetbrains.kotlin.idea.test.KotlinLightCodeInsightFixtureTestCase -import org.jetbrains.kotlin.idea.test.KotlinLightProjectDescriptor -import org.jetbrains.kotlin.idea.test.KotlinWithJdkAndRuntimeLightProjectDescriptor -import org.jetbrains.kotlin.psi.KtFile -import org.jetbrains.kotlin.test.KotlinTestUtils -import java.io.File -import java.nio.file.Paths - -abstract class AbstractSymbolByFqNameTest : KotlinLightCodeInsightFixtureTestCase() { - protected fun doTest(path: String) { - val fakeKtFile = myFixture.configureByText("file.kt", "fun a() {}") as KtFile - - val symbolData = SymbolByFqName.getSymbolDataFromFile(Paths.get(path)) - - val renderedSymbols = executeOnPooledThreadInReadAction { - analyse(fakeKtFile) { - val symbols = createSymbols(symbolData) - symbols.map { DebugSymbolRenderer.render(it) } - } - } - - val actual = SymbolByFqName.textWithRenderedSymbolData(path, renderedSymbols.joinToString(separator = "\n")) - KotlinTestUtils.assertEqualsToFile(File(path), actual) - } - - protected abstract fun KtAnalysisSession.createSymbols(symbolData: SymbolData): List - - override fun getDefaultProjectDescriptor(): KotlinLightProjectDescriptor = - KotlinWithJdkAndRuntimeLightProjectDescriptor.INSTANCE -} -