public void Login_Express_Checkout_Game_Page() { _driverCover.NavigateToUrl(_driverCover.BaseUrl + "en/play/eurojackpot/"); //Pay for tickets RegularGamePageObj regularGame = new RegularGamePageObj(_driver); //Go to single tab regularGame.ClickStandartGameButton(); regularGame.ClickBuyTicketsButton(); ExpressCheckoutObj checkout = new ExpressCheckoutObj(_driver); Thread.Sleep(TimeSpan.FromSeconds(1)); checkout.SignIn(_driverCover.Login, _driverCover.Password); _usersVerifications.CheckIfSignedIn_Mobile(); }
/// <summary> /// Performs once before all other tests. Buys a regular single ticket /// </summary> // [TestFixtureSetUp] public void Buy_Regular_Multi_Draw_Ticket(WayToPay merchant) { // Log in if (merchant != WayToPay.InternalBalance) { _commonActions.Log_In_Front_PageOne(_driverCover.Login, _driverCover.Password); } else { //If pay with internal balance we need to log in with different user _commonActions.Log_In_Front_PageOne(_driverCover.LoginTwo, _driverCover.Password); } _driverCover.NavigateToUrl(_driverCover.BaseUrl + "en/play/eurojackpot/"); //Pay for tickets RegularGamePageObj regularGame = new RegularGamePageObj(_driver); //Go to single tab regularGame.ClickStandartGameButton(); _totalPrice = regularGame.TotalPrice; _drawsToPlay = regularGame.NumberOfDraws; MerchantsObj merchants = regularGame.ClickBuyTicketsButton(); if (merchant != WayToPay.InternalBalance) { merchants.Pay(merchant); } else { CheckoutObj checkout = new CheckoutObj(_driver); checkout.ClickCompleteYourOrderButton(); } }
/// <summary> /// Buys a regular one-draw ticket /// </summary> /// <returns>Total price to pay</returns> public double BuyRegularOneDrawTicket_Front(WayToPay merchant, bool processOrder = true) { _driverCover.NavigateToUrl(_driverCover.BaseUrl + "en/play/powerball/"); //Pay for tickets RegularGamePageObj regularGame = new RegularGamePageObj(_driver); //go to single tab regularGame.ClickStandartGameButton(); //Select single draw regularGame.SelectOneTimeEntryGame(); double totalPrice = regularGame.TotalPrice; MerchantsObj merchants = regularGame.ClickBuyTicketsButton(); if (processOrder) { merchants.Pay(merchant); } else { merchants.Pay(merchant, false); } return totalPrice; }
/// <summary> /// Performs once before all other tests. Buys a regular single ticket /// </summary> // [TestFixtureSetUp] public void Buy_Regular_One_Draw_Ticket(WayToPay merchant) { // Log in if (merchant != WayToPay.InternalBalance) { _commonActions.Log_In_Front_PageOne(_driverCover.Login, _driverCover.Password); } else { //If pay with internal balance we need to log in with different user _commonActions.Log_In_Front_PageOne(_driverCover.LoginTwo, _driverCover.Password); } _driverCover.NavigateToUrl(_driverCover.BaseUrl + "en/play/el-gordo-de-la-primitiva/"); //Pay for tickets RegularGamePageObj regularGame = new RegularGamePageObj(_driver); //go to single tab regularGame.ClickStandartGameButton(); //Select single draw regularGame.SelectOneTimeEntryGame(); _totalPrice = regularGame.TotalPrice; MerchantsObj merchants = regularGame.ClickBuyTicketsButton(); if (merchant != WayToPay.InternalBalance) { merchants.Pay(merchant); } else { CheckoutObj checkout = new CheckoutObj(_driver); checkout.ClickCompleteYourOrderButton(); } }
/// <summary> /// Adds a regular ticket to the cart /// </summary> /// <param name="address"></param> public void AddRegularTicketToCart_Front(string address) { _driverCover.NavigateToUrl(_driverCover.BaseUrl + address); RegularGamePageObj game = new RegularGamePageObj(_driver); game.ClickStandartGameButton(); game.ClickBuyTicketsButton(); }