=pro Grab binary version for MIMA combatibility testing from a setting.
Thanks to @jsuereth
This commit is contained in:
parent
b00a89d713
commit
9311e9474e
12 changed files with 26 additions and 15 deletions
|
|
@ -13,4 +13,4 @@ OSGi.actor
|
|||
|
||||
libraryDependencies ++= Dependencies.actor
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-actor")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-actor").value
|
||||
|
|
|
|||
|
|
@ -13,4 +13,4 @@ OSGi.agent
|
|||
|
||||
libraryDependencies ++= Dependencies.agent
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-agent")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-agent").value
|
||||
|
|
|
|||
|
|
@ -13,4 +13,4 @@ OSGi.camel
|
|||
|
||||
libraryDependencies ++= Dependencies.camel
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-kernel")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-camel").value
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ OSGi.cluster
|
|||
|
||||
libraryDependencies ++= Dependencies.cluster
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-cluster")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-cluster").value
|
||||
|
||||
// disable parallel tests
|
||||
parallelExecution in Test := false
|
||||
|
|
|
|||
|
|
@ -11,4 +11,4 @@ Unidoc.javadocSettings
|
|||
|
||||
libraryDependencies ++= Dependencies.kernel
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-kernel")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-kernel").value
|
||||
|
|
|
|||
|
|
@ -9,4 +9,4 @@ Unidoc.scaladocSettings
|
|||
|
||||
Unidoc.javadocSettings
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-multi-node-testkit")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-multi-node-testkit").value
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ OSGi.persistence
|
|||
|
||||
Dependencies.persistence
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-persistence-experimental")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-persistence-experimental").value
|
||||
|
||||
fork in Test := true
|
||||
|
||||
|
|
|
|||
|
|
@ -15,4 +15,4 @@ libraryDependencies ++= Dependencies.remote
|
|||
|
||||
parallelExecution in Test := false
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-remote")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-remote").value
|
||||
|
|
|
|||
|
|
@ -13,4 +13,4 @@ OSGi.slf4j
|
|||
|
||||
libraryDependencies ++= Dependencies.slf4j
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-slf4j")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-slf4j").value
|
||||
|
|
|
|||
|
|
@ -16,4 +16,4 @@ libraryDependencies ++= Dependencies.testkit
|
|||
|
||||
initialCommands += "import akka.testkit._"
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-testkit")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-testkit").value
|
||||
|
|
|
|||
|
|
@ -13,4 +13,4 @@ OSGi.zeroMQ
|
|||
|
||||
libraryDependencies ++= Dependencies.zeroMQ
|
||||
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-zeromq")
|
||||
MimaKeys.previousArtifact := akkaPreviousArtifact("akka-zeromq").value
|
||||
|
|
|
|||
|
|
@ -503,13 +503,24 @@ object AkkaBuild extends Build {
|
|||
binaryIssueFilters ++= mimaIgnoredProblems
|
||||
)
|
||||
|
||||
def akkaPreviousArtifact(id: String, organization: String = "com.typesafe.akka", version: String = "2.3.0",
|
||||
crossVersion: String = "2.10"): Option[sbt.ModuleID] =
|
||||
def akkaPreviousArtifact(id: String): Def.Initialize[Option[sbt.ModuleID]] = Def.setting {
|
||||
if (enableMiMa) {
|
||||
val fullId = if (crossVersion.isEmpty) id else id + "_" + crossVersion
|
||||
Some(organization % fullId % version) // the artifact to compare binary compatibility with
|
||||
// Note: This is a little gross because we don't have a 2.3.0 release on Scala 2.11.x
|
||||
// This should be expanded if there are more deviations.
|
||||
val version: String =
|
||||
scalaBinaryVersion.value match {
|
||||
case "2.11" => "2.3.2"
|
||||
case _ => "2.3.0"
|
||||
}
|
||||
val fullId = crossVersion.value match {
|
||||
case _ : CrossVersion.Binary => id + "_" + scalaBinaryVersion.value
|
||||
case _ : CrossVersion.Full => id + "_" + scalaVersion.value
|
||||
case CrossVersion.Disabled => id
|
||||
}
|
||||
Some(organization.value % fullId % version) // the artifact to compare binary compatibility with
|
||||
}
|
||||
else None
|
||||
}
|
||||
|
||||
def loadSystemProperties(fileName: String): Unit = {
|
||||
import scala.collection.JavaConverters._
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue