Fix tests by using relative paths
LightTempDirTestFixtureImpl.findOrCreateChildDir can work only with relative paths
This commit is contained in:
@@ -25,7 +25,8 @@ import org.jetbrains.kotlin.test.KotlinTestUtils;
|
||||
import java.io.File;
|
||||
|
||||
public class PluginTestCaseBase {
|
||||
public static final String TEST_DATA_PROJECT_RELATIVE = "/idea/testData";
|
||||
public static final String TEST_DATA_DIR = "idea/testData";
|
||||
public static final String TEST_DATA_PROJECT_RELATIVE = "/" + TEST_DATA_DIR;
|
||||
|
||||
private PluginTestCaseBase() {
|
||||
}
|
||||
|
||||
+1
-1
@@ -30,7 +30,7 @@ import com.intellij.openapi.roots.ModifiableRootModel
|
||||
import com.intellij.openapi.roots.ContentEntry
|
||||
|
||||
class HighlightingWithDependentLibrariesTest : KotlinLightCodeInsightFixtureTestCase() {
|
||||
private val TEST_DATA_PATH = PluginTestCaseBase.getTestDataPathBase() + "/highlightingWithDependentLibraries"
|
||||
private val TEST_DATA_PATH = PluginTestCaseBase.TEST_DATA_DIR + "/highlightingWithDependentLibraries"
|
||||
|
||||
override fun getProjectDescriptor() = object : KotlinLightProjectDescriptor() {
|
||||
override fun configureModule(module: Module, model: ModifiableRootModel) {
|
||||
|
||||
+1
-1
@@ -59,7 +59,7 @@ class BuiltInDecompilerTest : AbstractBuiltInDecompilerTest() {
|
||||
}
|
||||
|
||||
class BuiltInDecompilerForWrongAbiVersionTest : AbstractBuiltInDecompilerTest() {
|
||||
override fun getTestDataPath() = PluginTestCaseBase.getTestDataPathBase() + "/decompiler/builtins/"
|
||||
override fun getTestDataPath() = PluginTestCaseBase.TEST_DATA_DIR + "/decompiler/builtins/"
|
||||
|
||||
override fun configureAndBuildFileStub(packageFqName: String): PsiFileStub<*> {
|
||||
myFixture.configureByFile(testDataPath + BuiltInSerializerProtocol.getBuiltInsFilePath(FqName(packageFqName)))
|
||||
|
||||
@@ -24,7 +24,7 @@ import org.jetbrains.kotlin.idea.test.PluginTestCaseBase
|
||||
import org.jetbrains.kotlin.psi.KtDeclaration
|
||||
import org.junit.Assert
|
||||
|
||||
private val FILE_WITH_KOTLIN_CODE = PluginTestCaseBase.getTestDataPathBase() + "/resolve/referenceInJava/dependency/dependencies.kt"
|
||||
private val FILE_WITH_KOTLIN_CODE = PluginTestCaseBase.TEST_DATA_DIR + "/resolve/referenceInJava/dependency/dependencies.kt"
|
||||
|
||||
abstract class AbstractReferenceResolveInJavaTest : AbstractReferenceResolveTest() {
|
||||
override fun doTest(path: String) {
|
||||
|
||||
Reference in New Issue
Block a user