Skip to content

Commit 2d0764a

Browse files
authored
Merge pull request #4222 from dotty-staging/avoid-timeouts
Split tests to avoid timeouts on the CI
2 parents 944b892 + bc53322 commit 2d0764a

10 files changed

+104
-46
lines changed

tests/run-with-compiler/i3947b.check

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,3 @@ byte
77

88
classOf[Char].getCanonicalName()
99
char
10-
11-
classOf[Short].getCanonicalName()
12-
short
13-
14-
classOf[Int].getCanonicalName()
15-
int
16-
17-
classOf[Long].getCanonicalName()
18-
long
19-
20-
classOf[Float].getCanonicalName()
21-
float
22-
23-
classOf[Double].getCanonicalName()
24-
double
25-
26-
classOf[Unit].getCanonicalName()
27-
void

tests/run-with-compiler/i3947b.scala

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,6 @@ object Test {
1818
test(classOf[Boolean])
1919
test(classOf[Byte])
2020
test(classOf[Char])
21-
test(classOf[Short])
22-
test(classOf[Int])
23-
test(classOf[Long])
24-
test(classOf[Float])
25-
test(classOf[Double])
26-
test(classOf[Unit])
2721
}
2822

2923
}

tests/run-with-compiler/i3947b2.check

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
2+
classOf[Short].getCanonicalName()
3+
short
4+
5+
classOf[Int].getCanonicalName()
6+
int
7+
8+
classOf[Long].getCanonicalName()
9+
long

tests/run-with-compiler/i3947b2.scala

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
2+
import scala.quoted._
3+
import dotty.tools.dotc.quoted.Toolbox._
4+
5+
object Test {
6+
7+
def main(args: Array[String]): Unit = {
8+
9+
def test[T](clazz: java.lang.Class[T]): Unit = {
10+
val lclazz = clazz.toExpr
11+
val name = '{ (~lclazz).getCanonicalName }
12+
println()
13+
println(name.show)
14+
println(name.run)
15+
}
16+
17+
// primitives
18+
test(classOf[Short])
19+
test(classOf[Int])
20+
test(classOf[Long])
21+
}
22+
23+
}

tests/run-with-compiler/i3947b3.check

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
2+
classOf[Float].getCanonicalName()
3+
float
4+
5+
classOf[Double].getCanonicalName()
6+
double
7+
8+
classOf[Unit].getCanonicalName()
9+
void

tests/run-with-compiler/i3947b3.scala

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
2+
import scala.quoted._
3+
import dotty.tools.dotc.quoted.Toolbox._
4+
5+
object Test {
6+
7+
def main(args: Array[String]): Unit = {
8+
9+
def test[T](clazz: java.lang.Class[T]): Unit = {
10+
val lclazz = clazz.toExpr
11+
val name = '{ (~lclazz).getCanonicalName }
12+
println()
13+
println(name.show)
14+
println(name.run)
15+
}
16+
17+
// primitives
18+
test(classOf[Float])
19+
test(classOf[Double])
20+
test(classOf[Unit])
21+
}
22+
23+
}

tests/run-with-compiler/i3947d.check

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,3 @@ Foo.Bar
77

88
classOf[Foo.Baz].getCanonicalName()
99
Foo.Baz
10-
11-
classOf[foo.Foo].getCanonicalName()
12-
foo.Foo
13-
14-
classOf[foo.Foo#Bar].getCanonicalName()
15-
foo.Foo.Bar
16-
17-
classOf[foo.Foo.Baz].getCanonicalName()
18-
foo.Foo.Baz

tests/run-with-compiler/i3947d.scala

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,6 @@ object Test {
1717
test(classOf[Foo])
1818
test(classOf[Foo#Bar])
1919
test(classOf[Foo.Baz])
20-
21-
test(classOf[foo.Foo])
22-
test(classOf[foo.Foo#Bar])
23-
test(classOf[foo.Foo.Baz])
2420
}
2521

2622
}
@@ -32,12 +28,3 @@ class Foo {
3228
object Foo {
3329
class Baz
3430
}
35-
36-
package foo {
37-
class Foo {
38-
class Bar
39-
}
40-
object Foo {
41-
class Baz
42-
}
43-
}

tests/run-with-compiler/i3947d2.check

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
2+
classOf[foo.Foo].getCanonicalName()
3+
foo.Foo
4+
5+
classOf[foo.Foo#Bar].getCanonicalName()
6+
foo.Foo.Bar
7+
8+
classOf[foo.Foo.Baz].getCanonicalName()
9+
foo.Foo.Baz

tests/run-with-compiler/i3947d2.scala

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
2+
import scala.quoted._
3+
import dotty.tools.dotc.quoted.Toolbox._
4+
5+
object Test {
6+
7+
def main(args: Array[String]): Unit = {
8+
9+
def test[T](clazz: java.lang.Class[T]): Unit = {
10+
val lclazz = clazz.toExpr
11+
val name = '{ (~lclazz).getCanonicalName }
12+
println()
13+
println(name.show)
14+
println(name.run)
15+
}
16+
17+
test(classOf[foo.Foo])
18+
test(classOf[foo.Foo#Bar])
19+
test(classOf[foo.Foo.Baz])
20+
}
21+
22+
}
23+
24+
package foo {
25+
class Foo {
26+
class Bar
27+
}
28+
object Foo {
29+
class Baz
30+
}
31+
}

0 commit comments

Comments
 (0)