@@ -1267,26 +1267,33 @@ trait ParallelTesting extends RunnerOrchestration { self =>
12671267
12681268 val (dirs, files) = compilationTargets(sourceDir, blacklist)
12691269
1270- val targets =
1271- files.map { f =>
1272- val classpath = createOutputDirsForFile(f, sourceDir, outDir)
1273- JointCompilationSource (testGroup.name, Array (f), flags.withClasspath(classpath.getPath), classpath, fromTasty = true )
1274- }
1270+ val filteredFiles = testFilter match {
1271+ case Some (str) => files.filter(_.getAbsolutePath.contains(str))
1272+ case None => files
1273+ }
1274+
1275+ val targets = filteredFiles.map { f =>
1276+ val classpath = createOutputDirsForFile(f, sourceDir, outDir)
1277+ JointCompilationSource (testGroup.name, Array (f), flags.withClasspath(classpath.getPath), classpath, fromTasty = true )
1278+ }
12751279 // TODO add SeparateCompilationSource from tasty?
12761280
12771281 val targets2 =
1278- files
1282+ filteredFiles
12791283 .filter(f => dotty.tools.io.File (f.toPath).changeExtension(" decompiled" ).exists)
12801284 .map { f =>
1281- val classpath = createOutputDirsForFile(f, sourceDir, outDir)
1282- JointCompilationSource (testGroup.name, Array (f), flags.withClasspath(classpath.getPath), classpath, decompilation = true )
1283- }
1285+ val classpath = createOutputDirsForFile(f, sourceDir, outDir)
1286+ JointCompilationSource (testGroup.name, Array (f), flags.withClasspath(classpath.getPath), classpath, decompilation = true )
1287+ }
12841288
12851289 // Create a CompilationTest and let the user decide whether to execute a pos or a neg test
12861290 val generateClassFiles = compileFilesInDir(f, flags0, blacklist)
12871291
12881292 val decompilationDir = outDir + sourceDir.getName + " _decompiled"
12891293
1294+ if (targets2.isEmpty)
1295+ new JFile (decompilationDir).mkdirs()
1296+
12901297 new TastyCompilationTest (
12911298 generateClassFiles.keepOutput,
12921299 new CompilationTest (targets).keepOutput,
0 commit comments