How can i mock HandlerThread
in Android. I am creating HandlerThread
in constructor of a class. I need to mock the HandlerThread
to write test case. Here is my code
HandlerThread("TimeoutHandlerThread").apply {
start()
workHandler = WorkHandler(looper)
}
Didn't find any clue.
How can i mock this
Thanks in advance.