Skip to content

Why do we need a Dispatcher as a rule to test coroutines

Devrath edited this page Jul 11, 2021 · 3 revisions
  • Dispatchers are not available for the test and androidTest packages so when testing the live data. There might be a possibility of failure.
  • Dispatchers rely upon the Main looper and available only during the execution of production code.
  • So we need to define a rule to handle the live data.

Clone this wiki locally