i have this function written in Kotlin
inline fun <T> handleEmptyResult(observable: Observable<T>,
crossinline resultEmptyCheckingFunc: (obj: T?) -> Boolean): Observable<T> {
return observable
.flatMap {
if (resultEmptyCheckingFunc(it)) {
Observable.error<T>(ResultEmptyError(Throwable()))
} else {
Observable.just(it)
}
}
}
But when i created unit tests for this function, it shows 0 coverage on the report. I am using jacoco for code coverage. Do you guys know how to unit test inline function properly? Thanks!