python (65.2k questions)
javascript (44.3k questions)
reactjs (22.7k questions)
java (20.8k questions)
c# (17.4k questions)
html (16.3k questions)
r (13.7k questions)
android (13k questions)
mockk, get error when using mockkstatic for stub static function
using io.mockk 1.11.0
having some class with @JvmStatic function
class LogUtil {
@JvmStatic
fun logData(jsonStr: String) {
val jsonObj = getDataJson(jsonStr)
if (jsonObj == nul...
lannyf
Votes: 0
Answers: 1
Android Unit test: Error: EmptyFragmentActivity cannot be cast to BaseActivity. How to get Instance of an Activity which is not defined in Manifest?
I am new to writing Android Test Cases. I am trying to write a test case for a project which is already developed. It has so many Activities and Fragments and we are using Navigation Graph for navigat...

Aanal Shah
Votes: 0
Answers: 0
Assert value comparison failed for TestObserver
I have a fake API service that will mock the failure. So when it calls through paging source I should be getting PagingSource.LoadResult.Error of the type returned by API service. This is my test func...
user2934930
Votes: 0
Answers: 0
mocck.spyk on a interface object failing
when spy on a interface object, it got
WARNING: Failed to transform class com/module/EvntHandleTest$test_evtListener$1$listener$1
java.lang.IncompatibleClassChangeError:
the class:
///
open class Te...
lannyf
Votes: 0
Answers: 0