-
Notifications
You must be signed in to change notification settings - Fork 337
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bugfix: Add back unintentionlly removed support for 2.11.x
Previously, we would use the lates scalfix version by default, which doesn't support Scala 2.11 by default. Now, we fall back to the latest version that supported it.
- Loading branch information
Showing
2 changed files
with
79 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
40 changes: 40 additions & 0 deletions
40
tests/slow/src/test/scala/tests/feature/Scala211ActionsLspSuite.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
package tests.feature | ||
|
||
import scala.meta.internal.metals.BuildInfo | ||
|
||
import tests.codeactions.BaseCodeActionLspSuite | ||
import scala.meta.internal.metals.codeactions.SourceOrganizeImports | ||
|
||
class Scala211ActionsLspSuite | ||
extends BaseCodeActionLspSuite("cross-code-actions") { | ||
|
||
override protected val scalaVersion: String = BuildInfo.scala211 | ||
|
||
check( | ||
"basic", | ||
""" | ||
|package a | ||
|import scala.concurrent.duration._ | ||
|import scala.concurrent.Future<<>> | ||
|import scala.concurrent.ExecutionContext.global | ||
| | ||
|object A { | ||
| val d = Duration(10, MICROSECONDS) | ||
| val k = Future.successful(1) | ||
|} | ||
|""".stripMargin, | ||
s"${SourceOrganizeImports.title}", | ||
""" | ||
|package a | ||
|import scala.concurrent.Future | ||
|import scala.concurrent.duration._ | ||
| | ||
|object A { | ||
| val d = Duration(10, MICROSECONDS) | ||
| val k = Future.successful(1) | ||
|} | ||
|""".stripMargin, | ||
kind = List(SourceOrganizeImports.kind), | ||
scalacOptions = List("-Ywarn-unused-import"), | ||
) | ||
} |