public void Scen01_ViewProductInfo_RandomProduct() { try { Results.WriteScenarioHeading("ViewProduct_01 - View Product Information(Brand, Title, Size, etc) of any Random Product."); home = home.NavigateToApplication().VerifyHomePage(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); Results.EndReport(); } catch(Exception e) { Logging.LogStop(e); throw; } }
public void Scen03_AddProductToShoppingBag() { try { Results.WriteScenarioHeading("ViewProduct_03 - Add a Product to shopping bag"); home = home.NavigateToApplication().VerifyHomePage(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); view = view.SelectSizeAndClickAddToShoppingBag(); ViewBag bag = view.OpenShoppingBag().VerifyShoppingBagPage(); Results.EndReport(); } catch (Exception e) { Logging.LogStop(e); throw; } }
public void Scen02_CheckOutAsExistingUser_LoginBeforeCheckout() { try { Results.WriteScenarioHeading("CheckOut_02 - Buy a Product As Existing User(Logs in before adding Prodcuct in Bag)."); home = home.NavigateToApplication().VerifyHomePage(); home = home.ClickSignIn().LoginAs(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); ViewBag bag = view.SelectSizeAndClickAddToShoppingBag().ClickViewBag().VerifyShoppingBagPage(); Shipping ship = bag.ClickCheckOutWithCreditCard().VerifyShippingTab(); Payment pay = ship.InputShippingInfo().VerifyPaymentTab(); ReviewYourOrder rev = pay.InputBillingInfo().VerifyReviewOrderTab(); OrderReceipt receipt = rev.ClickPlaceYourOrderButton(); receipt.GetOrderNumber(); Results.EndReport(); } catch (Exception e) { Logging.LogStop(e); throw; } }
public void Scen01_CheckOutAsGuestUser() { try { Results.WriteScenarioHeading("CheckOut_01 - Buy a Product As Guest User."); home = home.NavigateToApplication().VerifyHomePage(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); ViewBag bag = view.SelectSizeAndClickAddToShoppingBag().ClickViewBag().VerifyShoppingBagPage(); AccountSignIn acct = bag.ClickCheckOutWithCreditCard_AsGuestUser().VerifyAcctSignInPage(); Shipping ship = acct.CheckOutAsGuestUser().VerifyShippingTab(); Payment pay = ship.InputShippingInfo().VerifyPaymentTab(); ReviewYourOrder rev = pay.InputBillingInfo().VerifyReviewOrderTab(); OrderReceipt receipt = rev.ClickPlaceYourOrderButton(); receipt.GetOrderNumber(); Results.EndReport(); } catch(Exception e) { Logging.LogStop(e); throw; } }
public void Scen04_SendEmailToFriend() { try { Results.WriteScenarioHeading("ViewProduct_04 - Share Product Info with the friend via Email"); home = home.NavigateToApplication().VerifyHomePage(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); EmailAFriend email = view.ClickEmailAFriendButton(); view = email.EnterInfoAndSendEmail(); Results.EndReport(); } catch (Exception e) { Logging.LogStop(e); throw; } }
//[Test] public void Scen07_AddToWishList_CreateNewAccountDuringProcess() { try { Results.WriteScenarioHeading("ViewProduct_07 - Add a Product to Wish List(creating new account during process"); home = home.NavigateToApplication().VerifyHomePage(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); view.ClickAddToWishList_WhenNewAccountNeeded(); Results.EndReport(); } catch (Exception e) { Logging.LogStop(e); throw; } }
//[Test] public void Scen06_AddToWishList_LoginDuringProcess() { try { Results.WriteScenarioHeading("ViewProduct_06 - Add a Product to Wish List(Exisitng User logs in during process)"); home = home.NavigateToApplication().VerifyHomePage(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); view.ClickAddToWishList_WhenLoginNeeded(); Results.EndReport(); } catch (Exception e) { Logging.LogStop(e); throw; } }
public void Scen05_AddToWishList_AlreadyLoggedUser() { try { Results.WriteScenarioHeading("ViewProduct_05 - Add a Product to Wish List(when user already logged)"); home = home.NavigateToApplication().VerifyHomePage(); home = home.ClickSignIn().LoginAs(); ViewProduct view = home.ViewProduct().VerifyViewProductPage(); view = view.ClickAddToWishList_WhenAlreadyLoggedIn(); Results.EndReport(); } catch (Exception e) { Logging.LogStop(e); throw; } }
public void Scen05_ClickToViewProductInfoFromHome() { try { Results.WriteScenarioHeading("Home_05 - View an random Product from Home Page"); home = home.NavigateToApplication(); ViewProduct prod = home.ViewProduct(); Results.EndReport(); } catch (Exception e) { Logging.LogStop(e); throw; } }