Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scala 3.1.3 #2135

Merged
merged 1 commit into from Jul 20, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
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