package Ġapp . en velop . ui . don ate Ċ Ċ import Ġandroid . content . Intent Ċ import Ġandroid . net . Uri Ċ import Ġandroidx . test . espress o . Esp ress o . on View Ċ import Ġandroidx . test . espress o . action . View Actions . click Ċ import Ġandroidx . test . espress o . intent . Intent s . int ended Ċ import Ġandroidx . test . espress o . intent . matcher . Intent Matchers . has Action Ċ import Ġandroidx . test . espress o . intent . matcher . Intent Matchers . has Data Ċ import Ġandroidx . test . espress o . intent . rule . Intent s Test Rule Ċ import Ġandroidx . test . espress o . matcher . View Matchers . with Id Ċ import Ġandroidx . test . ext . junit . runners . Android JUnit 4 Ċ import Ġapp . en velop . R Ċ import Ġapp . en velop . test . App Helper Ċ import Ġorg . hamcrest . Core Matchers . all Of Ċ import Ġorg . junit . Rule Ċ import Ġorg . junit . Test Ċ import Ġorg . junit . runner . RunWith Ċ Ċ @ RunWith ( Android JUnit 4 :: class ) Ċ class ĠDon ate Activity Test Ġ{ ĊĊĠ Ġ@ get : Rule ĊĠ Ġval Ġintent Test Rule Ġ= ĠInt ents Test Rule < Don ate Activity >( Don ate Activity :: class . java ) ĊĠ Ġprivate Ġval Ġcontext Ġ= ĠApp Helper . context ĊĊĠ Ġ@ Test ĊĠ Ġfun Ġdon ate Crypto Test () Ġ{ ĊĠĠĠ Ġval Ġcrypto Uri Ġ= ĠUri . parse ( context . getString ( R . string . don ate _ crypto _ link )) ĊĠĠĠ Ġon View ( with Id ( R . id . don ate Crypto )). perform ( click ()) ĊĠĠĠ Ġintended ( all Of ( has Action ( Intent . ACTION _ VIEW ), Ġhas Data ( crypto Uri ))) ĊĠ Ġ} ĊĊĠ Ġ@ Test ĊĠ Ġfun Ġdon ate Stack s Test () Ġ{ ĊĠĠĠ Ġval Ġstacks Uri Ġ= ĠUri . parse ( context . getString ( R . string . don ate _ stack _ link )) ĊĠĠĠ Ġon View ( with Id ( R . id . don ate Stack s )). perform ( click ()) ĊĠĠĠ Ġintended ( all Of ( has Action ( Intent . ACTION _ VIEW ), Ġhas Data ( stacks Uri ))) ĊĠ Ġ} ĊĊĠ Ġ@ Test ĊĠ Ġfun Ġdon ate Pay pal Test () Ġ{ ĊĠĠĠ Ġval Ġstacks Uri Ġ= ĠUri . parse ( context . getString ( R . string . don ate _ paypal _ link )) ĊĠĠĠ Ġon View ( with Id ( R . id . don ate Pay pal )). perform ( click ()) ĊĠĠĠ Ġintended ( all Of ( has Action ( Intent . ACTION _ VIEW ), Ġhas Data ( stacks Uri ))) ĊĠ Ġ} Ċ } Ċ