pitest icon indicating copy to clipboard operation
pitest copied to clipboard

Have option to specify a source file path prefix for better Kotlin support

Open dalewking opened this issue 5 years ago • 0 comments

In Java if you have some class with qualified name like com.mycompany.category.applicationname.data.MyClass then that source file must be in a directory hierarchy like com/mycompany/category/application/data/MyClass.java which is enforced by Java. But with Kotlin it doesn't need to be that way and it is common to omit the common part of the directory structure (See https://kotlinlang.org/docs/reference/coding-conventions.html#directory-structure). So in this case that source file may be in src/kotlin/data/MyClass.kt.

Pitest does not allow for this and requires that you use the full directory structure. It would be nice if you could specify prefixes that can be omitted from the directory structure. So in this example to be able to specify a prefix of "com.mycompany.category.applicationname" and when looking for the source file look for both with and without the prefix.

dalewking avatar Sep 05 '20 20:09 dalewking