File tree Expand file tree Collapse file tree 4 files changed +39
-2
lines changed
main/scala/com/buransky/plugins/scoverage/samples/sbt/multiModule/module2
test/scala/com/buransky/plugins/scoverage/samples/sbt/multiModule/module2 Expand file tree Collapse file tree 4 files changed +39
-2
lines changed Original file line number Diff line number Diff line change 1+ organization := Common .organization
2+
3+ name := Common .baseName + " -module2"
4+
5+ version := Common .version
6+
7+ scalaVersion := " 2.10.3"
8+
9+ libraryDependencies ++= Seq (
10+ " org.scalatest" %% " scalatest" % " 2.0" % " test"
11+ )
12+
13+ ScoverageSbtPlugin .instrumentSettings
Original file line number Diff line number Diff line change 1+ package com .buransky .plugins .scoverage .samples .sbt .multiModule .module2
2+
3+ trait Animal {
4+ val legs : Int
5+ val eyes : Int
6+ val canFly : Boolean
7+ val canSwim : Boolean
8+ }
9+
10+ object Animal {
11+ def fancy (farm : Iterable [Animal ]): Iterable [Animal ] =
12+ farm.filter(_.legs > 10 ).filter(_.canFly).filter(_.canSwim)
13+ }
Original file line number Diff line number Diff line change 1+ package com .buransky .plugins .scoverage .samples .sbt .multiModule .module2
2+
3+ import org .scalatest .{Matchers , FlatSpec }
4+
5+ class AnimalSpec extends FlatSpec with Matchers {
6+ behavior of " fancy"
7+
8+ it should " do nothing" in {
9+ Animal .fancy(Nil ) should equal(Nil )
10+ }
11+ }
Original file line number Diff line number Diff line change @@ -4,12 +4,12 @@ sonar.projectVersion=1.0.0
44
55sonar.language =scala
66
7- sonar.modules =module1
7+ sonar.modules =module1,module2
88
99module1.sonar.sources =src/main/scala
1010module1.sonar.tests =src/test/scala
1111module1.sonar.scoverage.reportPath =target/scala-2.10/scoverage-report/scoverage.xml
1212
1313module2.sonar.sources =src/main/scala
1414module2.sonar.tests =src/test/scala
15- # module2.sonar.scoverage.reportPath=target/scala-2.10/scoverage-report/scoverage.xml
15+ module2.sonar.scoverage.reportPath =target/scala-2.10/scoverage-report/scoverage.xml
You can’t perform that action at this time.
0 commit comments