Skip to content

Commit

Permalink
fix: reliably run sbt-test scala2-compat/erasure
Browse files Browse the repository at this point in the history
  • Loading branch information
hamzaremmal committed Feb 5, 2025
1 parent c197afb commit da06de5
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
2 changes: 2 additions & 0 deletions sbt-test/scala2-compat/erasure/build.sbt
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
ThisBuild / fork := true

lazy val scala2Lib = project.in(file("scala2Lib"))
.settings(
scalaVersion := sys.props("plugin.scala2Version")
Expand Down
8 changes: 4 additions & 4 deletions sbt-test/scala2-compat/erasure/dottyApp/Api.scala
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,9 @@ class Z {
def objectARRAY_89(x: Array[AnyRef]): Unit = {}
def objectARRAY_90(x: Array[AnyVal]): Unit = {}

def objectARRAY_91(x: Array[Nothing]): Unit = {}
def objectARRAY_92(x: Array[Null]): Unit = {}
def objectARRAY_93(x: Array[_ <: Nothing]): Unit = {}
def objectARRAY_94(x: Array[_ <: Null]): Unit = {}
def nothing$ARRAY_91(x: Array[Nothing]): Unit = {}
def null$ARRAY_92(x: Array[Null]): Unit = {}
def nothing$ARRAY_93(x: Array[_ <: Nothing]): Unit = {}
def null$ARRAY_94(x: Array[_ <: Null]): Unit = {}

}
8 changes: 4 additions & 4 deletions sbt-test/scala2-compat/erasure/dottyApp/Main.scala
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ object Main {
z.c_40(dummy)
z.c_41(dummy)
z.c_42(dummy)
z.b_43(dummy)
//z.b_43(dummy)
z.c_44(dummy)
z.c_45(dummy)
z.b_46(dummy)
//z.b_46(dummy)
z.c_47(dummy)
// z.a_48(dummy)
// z.c_49(dummy)
Expand Down Expand Up @@ -103,8 +103,8 @@ object Main {
z.objectARRAY_90(dummy)
z.objectARRAY_91(dummy)
z.objectARRAY_92(dummy)
z.objectARRAY_93(dummy)
z.objectARRAY_94(dummy)
//z.objectARRAY_93(dummy)
//z.objectARRAY_94(dummy)

val methods = classOf[scala2Lib.Z].getDeclaredMethods.toList ++ classOf[dottyApp.Z].getDeclaredMethods.toList
methods.foreach { m =>
Expand Down

0 comments on commit da06de5

Please sign in to comment.