Skip to content

Commit

Permalink
fix path for tasty file
Browse files Browse the repository at this point in the history
  • Loading branch information
rochala committed Jul 12, 2022
1 parent 2c7d615 commit 3c3777c
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions compiler/test/dotty/tools/scripting/BashExitCodeTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ object BashExitCodeTests:
val testClassFile = temporaryDir.files.find(_.getName == s"$className.class")
assert(testClassFile.isDefined)
val commandline = (Seq(scalaPath, "-classpath", temporaryDir.absPath, className)).mkString(" ")
val (validTest, exitCode, o, e) = bashCommand(commandline)
val (validTest, exitCode, _, _) = bashCommand(commandline)
if verifyValid(validTest) then
assertEquals(expectedExitCode, exitCode)

Expand All @@ -74,7 +74,7 @@ object BashExitCodeTests:
*/
private def testCommandExitCode(args: Seq[String], expectedExitCode: Int): Unit =
val commandline = args.mkString(" ")
val (validTest, exitCode, output, erroutput) = bashCommand(commandline)
val (validTest, exitCode, _, _) = bashCommand(commandline)
if verifyValid(validTest) then
assertEquals(expectedExitCode, exitCode)

Expand Down Expand Up @@ -118,7 +118,9 @@ object BashExitCodeTests:
* Returns path to the generated tasty file for given directory and classname
*/
private def getGeneratedTastyPath(className: String)(using temporaryDir: File): String =
temporaryDir.toPath.resolve(s"$className.tasty").toString
val file = temporaryDir.files.find(_.getName == s"$className.tasty")
assert(file.isDefined)
file.get.absPath

@Category(Array(classOf[BootstrappedOnlyTests]))
class BashExitCodeTests:
Expand Down

0 comments on commit 3c3777c

Please sign in to comment.