Skip to content

Commit d0ec054

Browse files
committed
Issue 55 - Scala compilation removes Java classes compiled previously
1 parent 531bc3d commit d0ec054

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

src/main/groovy/org/scoverage/ScoverageExtension.groovy

+1-1
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,8 @@ class ScoverageExtension {
6969
def mainSourceSet = project.sourceSets.create('scoverage') {
7070
def original = project.sourceSets.getByName(SourceSet.MAIN_SOURCE_SET_NAME)
7171

72-
java.source(original.java)
7372
resources.source(original.resources)
73+
scala.source(original.java)
7474
scala.source(original.scala)
7575

7676
compileClasspath += original.compileClasspath + project.configurations.scoverage
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
package old;
2+
3+
public class World {
4+
public String getMessage() {
5+
return "Hello old boy";
6+
}
7+
}
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
package hello
22

33
object World {
4-
def say() = println("ahoy")
4+
def say() = {
5+
println(new old.World().getMessage())
6+
println("ahoy")
7+
}
58
}

0 commit comments

Comments
 (0)