<commit_before>package org.jetbrains.plugins.scala.compiler


import com.intellij.openapi.module.JavaModuleType
import com.intellij.openapi.roots.{DependencyScope, ModuleRootModificationUtil}
import com.intellij.testFramework.PsiTestUtil
import org.jetbrains.plugins.scala.DependencyManagerBase.RichStr
import org.jetbrains.plugins.scala.base.libraryLoaders.IvyManagedLoader
import org.jetbrains.plugins.scala.findUsages.compilerReferences.ScalaCompilerReferenceServiceFixture

class TransitiveDependencyClasspathTest extends ScalaCompilerReferenceServiceFixture {
  def testClasspathIncludesTransitiveModules(): Unit = {
    val moduleA = PsiTestUtil.addModule(getProject, JavaModuleType.getModuleType, "A", myFixture.getTempDirFixture.findOrCreateDir("A"))
    val moduleB = PsiTestUtil.addModule(getProject, JavaModuleType.getModuleType, "B", myFixture.getTempDirFixture.findOrCreateDir("B"))
    ModuleRootModificationUtil.addDependency(moduleA, getModule)
    ModuleRootModificationUtil.addDependency(moduleB, getModule)
    ModuleRootModificationUtil.addDependency(moduleA, moduleB, DependencyScope.COMPILE, true)
    setUpLibrariesFor(moduleA, moduleB)

    val libLoader = IvyManagedLoader("org.scalatest" %% "scalatest" % "3.2.0")
    libLoader.init(moduleB, version)

    val remoteServerConnectorBase = new RemoteServerConnectorBase(moduleA, None, new java.io.File("/tmp")) {
      def getResult(): Seq[java.io.File] = assemblyRuntimeClasspath()
    }

    val r = remoteServerConnectorBase.getResult()
    assert(r.exists(_.toString.contains("scalatest")))
  }

}
<commit_msg>Fix compile error on idea222.x<commit_after>package org.jetbrains.plugins.scala.compiler


import com.intellij.openapi.module.{JavaModuleType, Module}
import com.intellij.openapi.roots.{DependencyScope, ModuleRootModificationUtil}
import com.intellij.testFramework.PsiTestUtil
import org.jetbrains.plugins.scala.DependencyManagerBase.RichStr
import org.jetbrains.plugins.scala.base.libraryLoaders.IvyManagedLoader
import org.jetbrains.plugins.scala.findUsages.compilerReferences.ScalaCompilerReferenceServiceFixture

import java.io.File

class TransitiveDependencyClasspathTest extends ScalaCompilerReferenceServiceFixture {
  def testClasspathIncludesTransitiveModules(): Unit = {
    val moduleA = PsiTestUtil.addModule(getProject, JavaModuleType.getModuleType, "A", myFixture.getTempDirFixture.findOrCreateDir("A"))
    val moduleB = PsiTestUtil.addModule(getProject, JavaModuleType.getModuleType, "B", myFixture.getTempDirFixture.findOrCreateDir("B"))
    ModuleRootModificationUtil.addDependency(moduleA, getModule)
    ModuleRootModificationUtil.addDependency(moduleB, getModule)
    ModuleRootModificationUtil.addDependency(moduleA, moduleB, DependencyScope.COMPILE, true)
    setUpLibrariesFor(moduleA, moduleB)

    val libLoader = IvyManagedLoader("org.scalatest" %% "scalatest" % "3.2.0")
    libLoader.init(moduleB, version)

    val remoteServerConnectorBase = new TestRemoteServerConnectorBase(moduleA, None, new java.io.File("/tmp"))

    val r = remoteServerConnectorBase.getResult()
    assert(r.exists(_.toString.contains("scalatest")))
  }

}

class TestRemoteServerConnectorBase (module: Module, filesToCompile: Option[Seq[File]], outputDir: File)
    extends RemoteServerConnectorBase(module, filesToCompile, outputDir) {
  def getResult(): Seq[java.io.File] = assemblyRuntimeClasspath()
}

{'fraction_non_alphanumeric': 0.09679317446307738, 'fraction_numerical': 0.00264783759929391, 'mean_word_length': 6.962529274004684, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5716013', 'n_tokens_mistral': 1037, 'n_tokens_neox': 1009, 'n_words': 151}