package Ġcom . h ish am . b ush ar . home . data Ċ Ċ import Ġcom . google . common . truth . Truth . assertThat Ċ import Ġcom . h ish am . b ush ar . home . domain . entities . Movies Response Ċ import Ġio . mock k . co Every Ċ import Ġio . mock k . mock k Ċ import Ġkotlinx . coroutines . run Blocking Ċ import Ġorg . junit . Test Ċ Ċ internal Ġclass ĠMov ies Remote DataSource Test Ġ{ ĊĊĠĠĠ Ġprivate Ġval Ġapi : ĠMov ies Api Ġ= Ġmock k () ĊĊĠĠĠ Ġprivate Ġval ĠdataSource : ĠMov ies Remote DataSource Ġ= ĠMov ies Remote DataSource ( api ) ĊĊĠĠĠ Ġ@ Test ĊĠĠĠ Ġfun Ġ` test Ġlist Ġpopular Ġmovies `() Ġ= Ġrun Blocking Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġresponse : ĠMov ies Response Ġ= Ġmock k ( relax ed Ġ= Ġtrue ) ĊĠĠĠĠĠĠĠ Ġco Every Ġ{ Ġapi . list Pop ular Movies ( 1 ) Ġ} Ġreturns Ġresponse ĊĊĠĠĠĠĠĠĠ Ġval Ġresult Ġ= ĠdataSource . movie ( 1 ) ĊĊĠĠĠĠĠĠĠ ĠassertThat ( result ). isEqualTo ( response ) ĊĠĠĠ Ġ} Ċ } Ċ