package Ġcom . automation practice . pages . c arr in ho Ċ Ċ import Ġorg . openqa . selenium . WebDriver Ċ Ċ class ĠShop ping Cart Actions ( driver : ĠWebDriver ) Ġ: ĠShop ping Cart Screen ( driver ) Ġ{ ĊĊĠĠĠ Ġfun Ġpes quis ar ( valor : ĠString ){ ĊĠĠĠĠĠĠĠ Ġelem Input Search . apply Ġ{ Ġclear (); Ġsend Keys ( valor )} ĊĠĠĠĠĠĠĠ Ġclick ( elem Btn Search , Ġtrue ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun ĠaddTo Card ( value : ĠString =" Add Ġto Ġcart "){ ĊĠĠĠĠĠĠĠ Ġclick By JS ( elem Link AddTo Card ) ĊĠĠĠĠĠĠĠ Ġfind ( elem Btn Checkout ). contains ( value ) ĊĠĠĠĠĠĠĠ Ġclick ( find ( elem Btn Checkout )) ĊĠĠĠĠĠĠĠ Ġclick ( elem Link AddTo Checkout ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun Ġvalid ar C arr in ho ( texto : ĠString ) Ġ{ ĊĠĠĠĠĠĠĠ Ġelem Span Products Quantity . contains ( texto ) ĊĠĠĠ Ġ} Ċ Ċ } Ċ