@@ -58,7 +58,7 @@ class BashScriptsTests:
5858
5959 /* verify `dist/bin/scala` non-interference with command line args following script name */
6060 @ Test def verifyScalaArgs =
61- val commandline = (Seq (" SCALA_OPTS= " ,scalaPath, showArgsScript) ++ testScriptArgs).mkString(" " )
61+ val commandline = (Seq (" SCALA_OPTS= " , scalaPath, showArgsScript) ++ testScriptArgs).mkString(" " )
6262 val (validTest, exitCode, stdout, stderr) = bashCommand(commandline)
6363 if validTest then
6464 var fail = false
@@ -78,7 +78,7 @@ class BashScriptsTests:
7878 */
7979 @ Test def verifyScriptPathProperty =
8080 val scriptFile = testFiles.find(_.getName == " scriptPath.sc" ).get
81- val expected = s " / ${scriptFile.getName}"
81+ val expected = s " ${scriptFile.getName}"
8282 printf(" ===> verify valid system property script.path is reported by script [%s]\n " , scriptFile.getName)
8383 printf(" calling scriptFile: %s\n " , scriptFile)
8484 val (validTest, exitCode, stdout, stderr) = bashCommand(scriptFile.absPath)
@@ -105,7 +105,7 @@ class BashScriptsTests:
105105 if valid then printf(s " \n ===> success: classpath begins with %s, as reported by [%s] \n " , workingDirectory, scriptFile.getName)
106106 assert(valid, s " script ${scriptFile.absPath} did not report valid java.class.path first entry " )
107107
108- def existingPath : String = envOrElse(" PATH" ," " ).norm
108+ def existingPath : String = envOrElse(" PATH" , " " ).norm
109109 def adjustedPath = s " $javaHome/bin $psep$scalaHome/bin $psep$existingPath"
110110 def pathEntries = adjustedPath.split(psep).toList
111111
@@ -120,7 +120,7 @@ class BashScriptsTests:
120120 def fixHome (s : String ): String =
121121 s.startsWith(" ~" ) match {
122122 case false => s
123- case true => s.replaceFirst(" ~" ,userHome)
123+ case true => s.replaceFirst(" ~" , userHome)
124124 }
125125
126126 extension(s : String ) {
@@ -146,7 +146,7 @@ class BashScriptsTests:
146146 def absPath : String = f.getAbsolutePath.norm
147147 }
148148
149- lazy val psep : String = propOrElse(" path.separator" ," " )
149+ lazy val psep : String = propOrElse(" path.separator" , " " )
150150 lazy val osname = propOrElse(" os.name" , " " ).toLowerCase
151151
152152 lazy val scalacPath = s " $workingDirectory/dist/target/pack/bin/scalac " .norm
@@ -163,7 +163,7 @@ class BashScriptsTests:
163163 // else, SCALA_HOME if defined
164164 // else, not defined
165165 lazy val scalaHome =
166- if scalacPath.isFile then scalacPath.replaceAll(" /bin/scalac" ," " )
166+ if scalacPath.isFile then scalacPath.replaceAll(" /bin/scalac" , " " )
167167 else envOrElse(" SCALA_HOME" , " " ).norm
168168
169169 lazy val javaHome = envOrElse(" JAVA_HOME" , " " ).norm
@@ -172,7 +172,7 @@ class BashScriptsTests:
172172 (" JAVA_HOME" , javaHome),
173173 (" SCALA_HOME" , scalaHome),
174174 (" PATH" , adjustedPath),
175- ).filter { case (name,valu) => valu.nonEmpty }
175+ ).filter { case (name, valu) => valu.nonEmpty }
176176
177177 lazy val whichBash : String =
178178 var whichBash = " "
@@ -183,7 +183,7 @@ class BashScriptsTests:
183183
184184 whichBash
185185
186- def bashCommand (cmdstr : String , additionalEnvPairs: List [(String , String )] = Nil ): (Boolean , Int , Seq [String ], Seq [String ]) = {
186+ def bashCommand (cmdstr : String , additionalEnvPairs : List [(String , String )] = Nil ): (Boolean , Int , Seq [String ], Seq [String ]) = {
187187 var (stdout, stderr) = (List .empty[String ], List .empty[String ])
188188 if bashExe.toFile.exists then
189189 val cmd = Seq (bashExe, " -c" , cmdstr)
0 commit comments