mirror of
https://github.com/bitcoin-s/bitcoin-s.git
synced 2025-01-19 05:43:51 +01:00
Add scalameter test dependency and sbt settings
This commit is contained in:
parent
121cdf326d
commit
99ef45cce2
20
build.sbt
20
build.sbt
@ -108,6 +108,25 @@ lazy val commonTestWithDbSettings = Seq(
|
||||
|
||||
lazy val commonProdSettings = commonSettings
|
||||
|
||||
lazy val Benchmark = config("bench") extend Test
|
||||
lazy val benchSettings: Seq[Def.SettingsDefinition] = {
|
||||
//for scalameter
|
||||
//https://scalameter.github.io/home/download/
|
||||
//you can add benchmarking to a project by adding these to lines
|
||||
//to the projects build definition
|
||||
// .settings(benchSettings: _*)
|
||||
// .configs(Benchmark)
|
||||
List(
|
||||
unmanagedSourceDirectories in Test += baseDirectory.value / "src" / "bench" / "scala",
|
||||
testFrameworks += new TestFramework("org.scalameter.ScalaMeterFramework"),
|
||||
parallelExecution in Benchmark := false,
|
||||
outputStrategy in Benchmark := Some(StdoutOutput),
|
||||
fork in Benchmark := true,
|
||||
connectInput in Benchmark := true,
|
||||
inConfig(Benchmark)(Defaults.testSettings)
|
||||
)
|
||||
}
|
||||
|
||||
lazy val bitcoins = project
|
||||
.in(file("."))
|
||||
.aggregate(
|
||||
@ -130,6 +149,7 @@ lazy val bitcoins = project
|
||||
zmq
|
||||
)
|
||||
.settings(commonSettings: _*)
|
||||
// crossScalaVersions must be set to Nil on the aggregating project
|
||||
.settings(crossScalaVersions := Nil)
|
||||
.settings(libraryDependencies ++= Deps.root)
|
||||
.enablePlugins(ScalaUnidocPlugin, GitVersioning)
|
||||
|
@ -26,6 +26,7 @@ object Deps {
|
||||
val slickV = "3.3.1"
|
||||
val sqliteV = "3.27.2.1"
|
||||
val uJsonV = "0.7.1"
|
||||
val scalameterV = "0.17"
|
||||
}
|
||||
|
||||
object Compile {
|
||||
@ -73,6 +74,7 @@ object Deps {
|
||||
val ammonite = Compile.ammonite % "test"
|
||||
val playJson = Compile.playJson % "test"
|
||||
val akkaTestkit = "com.typesafe.akka" %% "akka-testkit" % V.akkaActorV withSources () withJavadoc ()
|
||||
val scalameter = "com.storm-enroute" %% "scalameter" % V.scalameterV % "test" withSources () withJavadoc ()
|
||||
}
|
||||
|
||||
val root = List(
|
||||
|
Loading…
Reference in New Issue
Block a user