mirror of https://github.com/sbt/sbt.git
Reproduce sbt/sbt#6745
This commit is contained in:
parent
b404431de4
commit
d4296d3e91
|
|
@ -97,6 +97,23 @@ object EvictionErrorSpec extends BaseIvySpecification {
|
|||
assert(EvictionError(report, m, overrideRules).incompatibleEvictions.isEmpty)
|
||||
}
|
||||
|
||||
test("it should selectively allow opt-out from the error despite assumed scheme") {
|
||||
val deps = Vector(`scala2.12.17`, `akkaActor2.6.0`, `swagger-akka-http1.4.0`)
|
||||
val m = module(defaultModuleId, deps, Some("2.12.17"))
|
||||
val report = ivyUpdate(m)
|
||||
val overrideRules = List("org.scala-lang.modules" %% "scala-java8-compat" % "always")
|
||||
assert(
|
||||
EvictionError(
|
||||
report = report,
|
||||
module = m,
|
||||
schemes = overrideRules,
|
||||
assumedVersionScheme = "early-semver",
|
||||
assumedVersionSchemeJava = "always",
|
||||
assumedEvictionErrorLevel = Level.Error,
|
||||
).assumedIncompatibleEvictions.isEmpty
|
||||
)
|
||||
}
|
||||
|
||||
// older Akka was on pvp
|
||||
def oldAkkaPvp = List("com.typesafe.akka" % "*" % "pvp")
|
||||
|
||||
|
|
@ -104,8 +121,12 @@ object EvictionErrorSpec extends BaseIvySpecification {
|
|||
ModuleID("com.typesafe.akka", "akka-actor", "2.1.4").withConfigurations(Some("compile")) cross CrossVersion.binary
|
||||
lazy val `akkaActor2.3.0` =
|
||||
ModuleID("com.typesafe.akka", "akka-actor", "2.3.0").withConfigurations(Some("compile")) cross CrossVersion.binary
|
||||
lazy val `akkaActor2.6.0` =
|
||||
ModuleID("com.typesafe.akka", "akka-actor", "2.6.0").withConfigurations(Some("compile")) cross CrossVersion.binary
|
||||
lazy val `scala2.10.4` =
|
||||
ModuleID("org.scala-lang", "scala-library", "2.10.4").withConfigurations(Some("compile"))
|
||||
lazy val `scala2.12.17` =
|
||||
ModuleID("org.scala-lang", "scala-library", "2.12.17").withConfigurations(Some("compile"))
|
||||
lazy val `scala2.13.3` =
|
||||
ModuleID("org.scala-lang", "scala-library", "2.13.3").withConfigurations(Some("compile"))
|
||||
lazy val `bananaSesame0.4` =
|
||||
|
|
@ -122,6 +143,9 @@ object EvictionErrorSpec extends BaseIvySpecification {
|
|||
("org.typelevel" %% "cats-parse" % "0.1.0").withConfigurations(Some("compile"))
|
||||
lazy val `cats-parse0.2.0` =
|
||||
("org.typelevel" %% "cats-parse" % "0.2.0").withConfigurations(Some("compile"))
|
||||
lazy val `swagger-akka-http1.4.0` =
|
||||
("com.github.swagger-akka-http" %% "swagger-akka-http" % "1.4.0")
|
||||
.withConfigurations(Some("compile"))
|
||||
|
||||
def dummyScalaModuleInfo(v: String): ScalaModuleInfo =
|
||||
ScalaModuleInfo(
|
||||
|
|
|
|||
Loading…
Reference in New Issue