package Ġengineer . trust me im ans o ftware . interaction reward ing ads . test lib Ċ Ċ import Ġandroid . content . Intent Ċ import Ġandroid . os . Bundle Ċ import Ġandroidx . test . core . app . Activity Scenario Ċ import Ġandroidx . test . platform . app . Instrumentation Registry Ċ import Ġengineer . trust me im ans o ftware . ad lib . manager . Ad Manager Ċ import Ġjunit . framework . TestCase . assertEquals Ċ import Ġorg . junit . Test Ċ class ĠTest Activity Test Ġ{ ĊĊĊĠĠĠ Ġ@ Test ĊĠĠĠ Ġfun Ġlaunch Test Activity _ in its Ad Manager () Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġscenario Ġ= ĠActivity Scenario . launch ( Test Activity :: class . java ) ĊĠĠĠĠĠĠĠ Ġscenario . on Activity () Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠassertEquals ( it . ad Manager , ĠAd Manager . instance ) ĊĠĠĠĠĠĠĠĠĠĠĠ ĠassertEquals ( it . ad Manager Ġ!= Ġnull , Ġtrue ) ĊĠĠĠĠĠĠĠĠĠĠĠ ĠassertEquals ( it . ad Manager ?. ad Fullscreen Activity Builder Ġ!= Ġnull , Ġtrue ) ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Test ĊĠĠĠ Ġfun Ġlaunch With Test Ad Fullscreen Activity Builder _ in its Custom Builder () Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġscenario Intent Ġ= ĠIntent ( Instrumentation Registry . get Instrumentation (). target Context , ĠTest Activity :: class . java ) ĊĠĠĠĠĠĠĠ Ġval Ġmy Bundle Ġ= ĠBundle () ĊĠĠĠĠĠĠĠ Ġmy Bundle . put Boolean ( Test Activity . opt Custom Ad Fullscreen Builder , Ġtrue ) ĊĠĠĠĠĠĠĠ Ġscenario Intent . put Extras ( my Bundle ) ĊĠĠĠĠĠĠĠ Ġval Ġscenario : ĠActivity Scenario < Test Activity > Ġ= ĠActivity Scenario . launch ( scenario Intent ) ĊĠĠĠĠĠĠĠ Ġscenario . on Activity Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠassertEquals ( ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġit . ad Manager ?. ad Fullscreen Activity Builder Ġis ĠTest Ad Fullscreen Activity Builder , ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġtrue ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ) ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} Ċ }