-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed package exclusion in reports for JaCoCo
Class filtering in JaCoCo took place by file name. Because previously the absolute path to the class file was taken, the filter worked on any occurrence of the specified string, even if it was no match starting from the root package. Now the search takes place relative to the classes root directory, which allows you to change the regular expression of the search, and remove arbitrary characters at the beginning in it. Fixes #543 PR #546
- Loading branch information
Showing
6 changed files
with
84 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
...-plugin/src/functionalTest/templates/sources/different-packages/main/kotlin/FooSources.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package foo.bar | ||
|
||
class FooClass { | ||
fun function() { | ||
println("Hello") | ||
} | ||
|
||
} |
11 changes: 11 additions & 0 deletions
11
...dle-plugin/src/functionalTest/templates/sources/different-packages/main/kotlin/Sources.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package org.jetbrains.foo | ||
|
||
class ExampleClass { | ||
fun used(value: Int): Int { | ||
return value + 1 | ||
} | ||
|
||
fun unused(value: Long): Long { | ||
return value - 1 | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
...e-plugin/src/functionalTest/templates/sources/different-packages/test/kotlin/TestClass.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package org.jetbrains.serialuser | ||
|
||
import org.jetbrains.foo.ExampleClass | ||
import foo.bar.FooClass | ||
import kotlin.test.Test | ||
|
||
class TestClass { | ||
@Test | ||
fun simpleTest() { | ||
ExampleClass().used(-20) | ||
FooClass().function() | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters