Skip to content

Commit

Permalink
Merge branch 'feature-scala-3.1.3' of https://github.com/cheeseng/sca…
Browse files Browse the repository at this point in the history
…latest into 3.2.x-new
  • Loading branch information
cheeseng committed Jul 20, 2022
2 parents 67c15f8 + 8fb4ab8 commit 7b73c64
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
Expand Up @@ -127,7 +127,7 @@ trait RefSpecLike extends TestSuite with Informing with Notifying with Alerting
case other: Throwable if (!Suite.anExceptionThatShouldCauseAnAbort(other)) =>
if (ScalaTestVersions.BuiltForScalaVersion == "2.12")
throw new NotAllowedException(FailureMessages.exceptionWasThrownInObject(Prettifier.default, UnquotedString(other.getClass.getName), UnquotedString(scopeDesc)), Some(other), Right((_: StackDepthException) => 9))
else if (ScalaTestVersions.BuiltForScalaVersion.startsWith("2.13"))
else if (ScalaTestVersions.BuiltForScalaVersion.startsWith("2.13") || ScalaTestVersions.BuiltForScalaVersion.startsWith("3."))
throw new NotAllowedException(FailureMessages.exceptionWasThrownInObject(Prettifier.default, UnquotedString(other.getClass.getName), UnquotedString(scopeDesc)), Some(other), Right((_: StackDepthException) => 7))
else
throw new NotAllowedException(FailureMessages.exceptionWasThrownInObject(Prettifier.default, UnquotedString(other.getClass.getName), UnquotedString(scopeDesc)), Some(other), Right((_: StackDepthException) => 8))
Expand Down
Expand Up @@ -129,7 +129,7 @@ class ShouldCompileSpec extends AnyFunSpec {
assert(e.message.get.indexOf("println(\"test)") >= 0)
assert(e.failedCodeFileName === (Some(fileName)))
assert(e.failedCodeLineNumber === (Some(thisLineNumber - 6)))
assert(e.message.get.indexOf(if (ScalaTestVersions.BuiltForScalaVersion.startsWith("3.")) "')' expected, but eof found" else "unclosed string literal") >= 0)
assert(e.message.get.indexOf(if (ScalaTestVersions.BuiltForScalaVersion.startsWith("3.")) "expression expected but erroneous token found" else "unclosed string literal") >= 0)
}
}
}
Expand Down
Expand Up @@ -591,7 +591,7 @@ class DirectExpectationsSpec extends AnyFunSpec {
assert(fact.factMessage == Resources.expectedNoErrorButGotParseError("reflective compilation has failed: \n\nunclosed string literal\n')' expected but '}' found.", "\nprintln(\"test)\n"))
else if (ScalaTestVersions.BuiltForScalaVersion.startsWith("3."))
assert(fact.factMessage == Resources.expectedNoErrorButGotParseError(
"')' expected, but eof found",
"expression expected but erroneous token found",
"""
|println("test)
|""".stripMargin
Expand Down Expand Up @@ -692,7 +692,7 @@ class DirectExpectationsSpec extends AnyFunSpec {
assert(fact.factMessage == Resources.expectedTypeErrorButGotParseError("reflective compilation has failed: \n\nunclosed string literal\n')' expected but '}' found.", "\nprintln(\"test)\n"))
else if (ScalaTestVersions.BuiltForScalaVersion.startsWith("3."))
assert(fact.factMessage == Resources.expectedTypeErrorButGotParseError(
"')' expected, but eof found",
"expression expected but erroneous token found",
"""
|println("test)
|""".stripMargin
Expand Down
Expand Up @@ -643,7 +643,7 @@ class ExpectationsSpec extends AnyFunSpec with Expectations {
assert(fact.factMessage == Resources.expectedNoErrorButGotParseError("reflective compilation has failed: \n\nunclosed string literal\n')' expected but '}' found.", "\nprintln(\"test)\n"))
else if (ScalaTestVersions.BuiltForScalaVersion.startsWith("3."))
assert(fact.factMessage == Resources.expectedNoErrorButGotParseError(
"')' expected, but eof found",
"expression expected but erroneous token found",
"""
|println("test)
|""".stripMargin
Expand Down Expand Up @@ -788,7 +788,7 @@ class ExpectationsSpec extends AnyFunSpec with Expectations {
assert(fact.factMessage == Resources.expectedTypeErrorButGotParseError("reflective compilation has failed: \n\nunclosed string literal\n')' expected but '}' found.", "\nprintln(\"test)\n"))
else if (ScalaTestVersions.BuiltForScalaVersion.startsWith("3."))
assert(fact.factMessage == Resources.expectedTypeErrorButGotParseError(
"')' expected, but eof found",
"expression expected but erroneous token found",
"""
|println("test)
|""".stripMargin
Expand Down
2 changes: 1 addition & 1 deletion project/DottyBuild.scala
Expand Up @@ -19,7 +19,7 @@ trait DottyBuild { this: BuildCommons =>

// List of available night build at https://repo1.maven.org/maven2/ch/epfl/lamp/dotty-compiler_0.27/
// lazy val dottyVersion = dottyLatestNightlyBuild.get
lazy val dottyVersion = System.getProperty("scalatest.dottyVersion", "3.1.0")
lazy val dottyVersion = System.getProperty("scalatest.dottyVersion", "3.1.3")
lazy val dottySettings = List(
scalaVersion := dottyVersion,
scalacOptions ++= List("-language:implicitConversions", "-noindent", "-Xprint-suspension")
Expand Down

0 comments on commit 7b73c64

Please sign in to comment.