@@ -33,10 +33,12 @@ class CompilationTests extends ParallelTesting {
3333
3434 // @Test // enable to test compileStdLib separately with detailed stats
3535 def compileStdLib : Unit = {
36+ implicit val testGroup : TestGroup = TestGroup (" compileStdLib" )
3637 compileList(" compileStdLib" , StdLibSources .whitelisted, scala2Mode.and(" -migration" , " -Yno-inline" , " -Ydetailed-stats" ))
3738 }.checkCompile()
3839
3940 @ Test def compilePos : Unit = {
41+ implicit val testGroup : TestGroup = TestGroup (" compilePos" )
4042 compileList(" compileStdLib" , StdLibSources .whitelisted, scala2Mode.and(" -migration" , " -Yno-inline" )) +
4143 compileDir(" ../compiler/src/dotty/tools/dotc/ast" , defaultOptions) +
4244 compileDir(" ../compiler/src/dotty/tools/dotc/config" , defaultOptions) +
@@ -102,6 +104,7 @@ class CompilationTests extends ParallelTesting {
102104 }.checkCompile()
103105
104106 @ Test def posTwice : Unit = {
107+ implicit val testGroup : TestGroup = TestGroup (" posTwice" )
105108 compileFile(" ../tests/pos/Labels.scala" , defaultOptions) +
106109 compileFilesInDir(" ../tests/pos-java-interop" , defaultOptions) +
107110 compileFile(" ../tests/pos/t2168.scala" , defaultOptions) +
@@ -160,6 +163,7 @@ class CompilationTests extends ParallelTesting {
160163 // Negative tests ------------------------------------------------------------
161164
162165 @ Test def compileNeg : Unit = {
166+ implicit val testGroup : TestGroup = TestGroup (" compileNeg" )
163167 compileShallowFilesInDir(" ../tests/neg" , defaultOptions) +
164168 compileShallowFilesInDir(" ../tests/neg/no-optimise" , defaultOptions) +
165169 compileFile(" ../tests/neg/customArgs/typers.scala" , allowDoubleBindings) +
@@ -189,13 +193,15 @@ class CompilationTests extends ParallelTesting {
189193 // Run tests -----------------------------------------------------------------
190194
191195 @ Test def runAll : Unit = {
196+ implicit val testGroup : TestGroup = TestGroup (" runAll" )
192197 compileFilesInDir(" ../tests/run" , defaultOptions) +
193198 compileFilesInDir(" ../tests/run-no-optimise" , defaultOptions)
194199 }.checkRuns()
195200
196201 // Generic java signatures tests ---------------------------------------------
197202
198203 @ Test def genericJavaSignatures : Unit = {
204+ implicit val testGroup : TestGroup = TestGroup (" genericJavaSignatures" )
199205 compileFilesInDir(" ../tests/generic-java-signatures" , defaultOptions)
200206 }.checkRuns()
201207
@@ -205,6 +211,7 @@ class CompilationTests extends ParallelTesting {
205211 // lower level of concurrency as to not kill their running VMs
206212
207213 @ Test def testPickling : Unit = {
214+ implicit val testGroup : TestGroup = TestGroup (" testPickling" )
208215 compileDir(" ../compiler/src/dotty/tools" , picklingOptions) +
209216 compileDir(" ../compiler/src/dotty/tools/dotc" , picklingOptions) +
210217 compileFilesInDir(" ../tests/new" , picklingOptions) +
@@ -233,18 +240,23 @@ class CompilationTests extends ParallelTesting {
233240 * version of Dotty
234241 */
235242 @ Test def tastyBootstrap : Unit = {
243+ implicit val testGroup : TestGroup = TestGroup (" tastyBootstrap/tests" )
244+ val dotty1Group = TestGroup (" tastyBootstrap/dotty1" )
245+ val dotty2Group = TestGroup (" tastyBootstrap/dotty2" )
246+ val libGroup = TestGroup (" tastyBootstrap/lib" )
247+
236248 val opt = TestFlags (
237249 // compile with bootstrapped library on cp:
238- defaultOutputDir + " lib /src/:" +
250+ defaultOutputDir + libGroup + " /src/:" +
239251 // as well as bootstrapped compiler:
240- defaultOutputDir + " dotty1 /dotty/:" +
252+ defaultOutputDir + dotty1Group + " /dotty/:" +
241253 Jars .dottyInterfaces,
242254 Array (" -Ycheck-reentrant" )
243255 )
244256
245- def lib =
257+ val lib =
246258 compileDir(" ../library/src" ,
247- defaultOptions.and(" -Ycheck-reentrant" , " -strict" , " -priorityclasspath" , defaultOutputDir))
259+ defaultOptions.and(" -Ycheck-reentrant" , " -strict" , " -priorityclasspath" , defaultOutputDir))(libGroup)
248260
249261 val compilerDir = Paths .get(" ../compiler/src" )
250262 val compilerSources = sources(Files .walk(compilerDir))
@@ -263,19 +275,8 @@ class CompilationTests extends ParallelTesting {
263275 val backendJvmSources =
264276 sources(Files .list(backendJvmDir), excludedFiles = backendJvmExcluded)
265277
266- def dotty1 = {
267- compileList(
268- " dotty" ,
269- compilerSources ++ backendSources ++ backendJvmSources,
270- opt)
271- }
272-
273- def dotty2 = {
274- compileList(
275- " dotty" ,
276- compilerSources ++ backendSources ++ backendJvmSources,
277- opt)
278- }
278+ val dotty1 = compileList(" dotty" , compilerSources ++ backendSources ++ backendJvmSources, opt)(dotty1Group)
279+ val dotty2 = compileList(" dotty" , compilerSources ++ backendSources ++ backendJvmSources, opt)(dotty2Group)
279280
280281 val tests = {
281282 lib.keepOutput :: dotty1.keepOutput :: {
@@ -296,19 +297,20 @@ class CompilationTests extends ParallelTesting {
296297 }.keepOutput :: Nil
297298 }.map(_.checkCompile())
298299
299- assert(new java.io.File (" ../out/dotty1/dotty/" ).exists)
300- assert(new java.io.File (" ../out/dotty2/dotty/" ).exists)
300+ assert(new java.io.File (s " ../out/ $dotty1Group/dotty/ " ).exists)
301+ assert(new java.io.File (s " ../out/ $dotty2Group/dotty/ " ).exists)
302+ assert(new java.io.File (s " ../out/ $libGroup/src/ " ).exists)
301303 compileList(" idempotency" , List (" ../tests/idempotency/BootstrapChecker.scala" , " ../tests/idempotency/IdempotencyCheck.scala" ), defaultOptions).checkRuns()
302304
303305 tests.foreach(_.delete())
304306 }
305307
306308 @ Category (Array (classOf [SlowTests ]))
307309 @ Test def testOptimised : Unit = {
308- val outputDir = defaultOutputDir + " optimised/"
309- compileFilesInDir(" ../tests/pos" , defaultOptimised, outputDir ).checkCompile()
310- compileFilesInDir(" ../tests/run" , defaultOptimised, outputDir ).checkRuns()
311- compileShallowFilesInDir(" ../tests/neg" , defaultOptimised, outputDir ).checkExpectedErrors()
310+ implicit val testGroup : TestGroup = TestGroup ( " optimised/testOptimised " )
311+ compileFilesInDir(" ../tests/pos" , defaultOptimised).checkCompile()
312+ compileFilesInDir(" ../tests/run" , defaultOptimised).checkRuns()
313+ compileShallowFilesInDir(" ../tests/neg" , defaultOptimised).checkExpectedErrors()
312314 }
313315
314316 private val (compilerSources, backendSources, backendJvmSources) = {
0 commit comments