package Ġorg . od k . collect . android . support . pages Ċ Ċ import Ġandroidx . test . espress o . Esp ress o . on View Ċ import Ġandroidx . test . espress o . action . View Actions Ċ import Ġandroidx . test . espress o . assertion . View Assertions . matches Ċ import Ġandroidx . test . espress o . matcher . View Matchers . has Desc endant Ċ import Ġandroidx . test . espress o . matcher . View Matchers . is Displayed Ċ import Ġandroidx . test . espress o . matcher . View Matchers . with Content Description Ċ import Ġandroidx . test . espress o . matcher . View Matchers . with Id Ċ import Ġandroidx . test . espress o . matcher . View Matchers . with Text Ċ import Ġandroidx . test . rule . Activity Test Rule Ċ import Ġorg . hamcrest . Matchers . all Of Ċ import Ġorg . od k . collect . android . R Ċ Ċ internal Ġclass ĠProject Settings Dialog Page ( rule : ĠActivity Test Rule <* >) Ġ: ĠPage < Project Settings Dialog Page >( rule ) Ġ{ ĊĠĠĠ Ġoverride Ġfun Ġassert On Page (): ĠProject Settings Dialog Page Ġ{ ĊĠĠĠĠĠĠĠ Ġassert Text ( R . string . projects ) ĊĠĠĠĠĠĠĠ Ġreturn Ġthis ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġclick General Settings (): ĠGeneral Settings Page Ġ{ ĊĠĠĠĠĠĠĠ Ġclick On String ( R . string . general _ preferences ) ĊĠĠĠĠĠĠĠ Ġreturn ĠGeneral Settings Page ( rule ). assert On Page () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġclick Admin Settings (): ĠAdmin Settings Page Ġ{ ĊĠĠĠĠĠĠĠ Ġclick On String ( R . string . admin _ preferences ) ĊĠĠĠĠĠĠĠ Ġreturn ĠAdmin Settings Page ( rule ). assert On Page () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġclick Admin Settings With Password ( password : ĠString ?): ĠAdmin Settings Page Ġ{ ĊĠĠĠĠĠĠĠ Ġclick On String ( R . string . admin _ preferences ) ĊĠĠĠĠĠĠĠ Ġinput Text ( password ) ĊĠĠĠĠĠĠĠ Ġclick OK On Dialog () ĊĠĠĠĠĠĠĠ Ġreturn ĠAdmin Settings Page ( rule ). assert On Page () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġclick About (): ĠAbout Page Ġ{ ĊĠĠĠĠĠĠĠ Ġclick On String ( R . string . about _ preferences ) ĊĠĠĠĠĠĠĠ Ġreturn ĠAbout Page ( rule ). assert On Page () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġclick Add Project (): ĠAdd Project Dialog Page Ġ{ ĊĠĠĠĠĠĠĠ Ġon View ( with Id ( R . id . add _ project _ button )). perform ( View Actions . click ()) ĊĠĠĠĠĠĠĠ Ġreturn ĠAdd Project Dialog Page ( rule ). assert On Page () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġassert Current Project ( name : ĠString ): ĠProject Settings Dialog Page Ġ{ ĊĠĠĠĠĠĠĠ Ġon View ( all Of ( has Desc endant ( with Text ( name )), Ġwith Content Description ( get Translated String ( R . string . using _ project , Ġname )) )). check ( matches ( is Displayed ())) ĊĠĠĠĠĠĠĠ Ġreturn Ġthis ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġassert Inactive Project ( name : ĠString ): ĠProject Settings Dialog Page Ġ{ ĊĠĠĠĠĠĠĠ Ġon View ( all Of ( has Desc endant ( with Text ( name )), Ġwith Content Description ( get Translated String ( R . string . switch _ to _ project , Ġname )) )). check ( matches ( is Displayed ())) ĊĠĠĠĠĠĠĠ Ġreturn Ġthis ĊĠĠĠ Ġ} Ċ } Ċ