Skip to content

Commit

Permalink
Turn on and configure test coverage reporting
Browse files Browse the repository at this point in the history
  • Loading branch information
travisbrown committed Jan 30, 2015
1 parent 421ab3f commit c754bbf
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 6 deletions.
7 changes: 6 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,9 @@ jdk:
- oraclejdk7
- oraclejdk8

script: "sbt ++$TRAVIS_SCALA_VERSION test it:test"
script:
- sbt ++$TRAVIS_SCALA_VERSION coverage test it:test

after_success:
- sbt coverageAggregate
- sbt coveralls
7 changes: 7 additions & 0 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import scoverage.ScoverageSbtPlugin.ScoverageKeys.coverageExcludedPackages

lazy val commonSettings = Seq(
organization := "io.github.finagle",
version := "0.0.1",
Expand Down Expand Up @@ -33,13 +35,15 @@ lazy val core = project
.settings(moduleName := "finagle-serial-core")
.settings(commonSettings: _*)
.settings(publishSettings: _*)
.disablePlugins(CoverallsPlugin)

lazy val test = project
.settings(moduleName := "finagle-serial-test")
.settings(commonSettings: _*)
.settings(publishSettings: _*)
.settings(libraryDependencies ++= testDependencies)
.dependsOn(core)
.disablePlugins(CoverallsPlugin)

lazy val scodecSettings = Seq(
resolvers += Resolver.sonatypeRepo("snapshots"),
Expand All @@ -60,6 +64,7 @@ lazy val scodec = project
.settings(publishSettings: _*)
.settings(scodecSettings: _*)
.dependsOn(core, test % "it")
.disablePlugins(CoverallsPlugin)

lazy val benchmark = project
.settings(moduleName := "finagle-serial-benchmark")
Expand All @@ -73,7 +78,9 @@ lazy val benchmark = project
"com.twitter" %% "scrooge-core" % "3.17.0"
)
).settings(com.twitter.scrooge.ScroogeSBT.newSettings: _*)
.settings(coverageExcludedPackages := "i\\.g\\.f\\.s\\..*")
.dependsOn(core, scodec)
.disablePlugins(CoverallsPlugin)

lazy val publishSettings = Seq(
publishMavenStyle := true,
Expand Down
10 changes: 5 additions & 5 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ resolvers ++= Seq(
)

addSbtPlugin("com.eed3si9n" % "sbt-unidoc" % "0.3.1")

// Used only in the benchmark project
addSbtPlugin("com.twitter" %% "scrooge-sbt-plugin" % "3.14.1")

addSbtPlugin("com.typesafe.sbt" % "sbt-pgp" % "0.8.3")

addSbtPlugin("org.scoverage" % "sbt-coveralls" % "1.0.0.BETA1")
addSbtPlugin("org.scoverage" % "sbt-scoverage" % "1.0.4")
addSbtPlugin("pl.project13.scala" % "sbt-jmh" % "0.1.8")

// Used only in the benchmark project
addSbtPlugin("com.twitter" %% "scrooge-sbt-plugin" % "3.14.1")

0 comments on commit c754bbf

Please sign in to comment.