[tests] Use full paths with the proper extensions to KLIBs in LibraryProvider

^KT-61098
This commit is contained in:
Dmitriy Dolovov
2023-11-14 09:45:55 +01:00
committed by Space Team
parent 82b08a813b
commit 1183244455
4 changed files with 4 additions and 7 deletions
@@ -288,7 +288,7 @@ class ClassicFrontendFacade(
val dependencies = mutableListOf<ModuleDescriptorImpl>()
return resolvedLibraries.map { resolvedLibrary ->
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryName) {
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryFile.absolutePath) {
val storageManager = LockBasedStorageManager("ModulesStructure")
val isBuiltIns = resolvedLibrary.library.unresolvedDependencies.isEmpty()
@@ -199,8 +199,7 @@ private fun loadResolvedLibraries(
val dependencies = mutableListOf<ModuleDescriptorImpl>()
return resolvedLibraries.map { resolvedLibrary ->
// resolvedLibrary.library.libraryName in fact resolves to (modified) file path, which is confising and maybe should be refactored
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryName) {
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryFile.absolutePath) {
// TODO: check safety of the approach of creating a separate storage manager per library
val storageManager = LockBasedStorageManager("ModulesStructure")
@@ -198,8 +198,7 @@ private fun loadResolvedLibraries(
val dependencies = mutableListOf<ModuleDescriptorImpl>()
return resolvedLibraries.map { resolvedLibrary ->
// resolvedLibrary.library.libraryName in fact resolves to (modified) file path, which is confising and maybe should be refactored
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryName) {
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryFile.absolutePath) {
// TODO: check safety of the approach of creating a separate storage manager per library
val storageManager = LockBasedStorageManager("ModulesStructure")
@@ -176,8 +176,7 @@ private fun loadResolvedLibraries(
val dependencies = mutableListOf<ModuleDescriptorImpl>()
return resolvedLibraries.map { resolvedLibrary ->
// resolvedLibrary.library.libraryName in fact resolves to (modified) file path, which is confusing and maybe should be refactored
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryName) {
testServices.libraryProvider.getOrCreateStdlibByPath(resolvedLibrary.library.libraryFile.absolutePath) {
// TODO: check safety of the approach of creating a separate storage manager per library
val storageManager = LockBasedStorageManager("ModulesStructure")