public void Purchase_WhiteOpticalKeyboard()
        {
            string itemUrl = "Wireless-White-2-4G-Optical-Keyboard-and-Mouse-USB-Receiver-Kit-For-PC-/360649772948?pt=LH_DefaultDomain_2&hash=item53f866cf94";
            string itemPrice = "C $20.86";
            ClientInfo currentClientInfo = new ClientInfo()
            {
                FirstName = "Anton",
                LastName = "Angelov",
                Country = "Bulgaria",
                Address1 = "33 Alexander Malinov Blvd.",
                City = "Stara Zagora",
                Zip = "6000",
                Phone = "0035964644885",
                Email = "*****@*****.**"
            };
            ItemPage itemPage = new ItemPage();
            CheckoutPage checkoutPage = new CheckoutPage();
            ShippingAddressPage shippingAddressPage = new ShippingAddressPage();
            SignInPage signInPage = new SignInPage();

            itemPage.Navigate(itemUrl);
            itemPage.Validate().Price(itemPrice);
            itemPage.ClickBuyNowButton();
            signInPage.ClickContinueAsGuestButton();
            shippingAddressPage.FillShippingInfo(currentClientInfo);
            shippingAddressPage.Validate().Subtotal(itemPrice);
            shippingAddressPage.ClickContinueButton();
            checkoutPage.Validate().Subtotal(itemPrice);
        }
        public void Purchase_Casio_GShock()
        {
            string itemUrl = "Casio-G-Shock-Standard-GA-100-1A2-Mens-Watch-Brand-New-/161209550414?pt=LH_DefaultDomain_15&hash=item2588d6864e";
            string itemPrice = "AU $168.00";
            ClientInfo currentClientInfo = new ClientInfo()
            {
                FirstName = "Anton",
                LastName = "Angelov",
                Country = "Bulgaria",
                Address1 = "33 Alexander Malinov Blvd.",
                City = "Sofia",
                Zip = "1729",
                Phone = "0035964644885",
                Email = "*****@*****.**"
            };
            ItemPage itemPage = new ItemPage();
            CheckoutPage checkoutPage = new CheckoutPage();
            ShippingAddressPage shippingAddressPage = new ShippingAddressPage();
            SignInPage signInPage = new SignInPage();

            itemPage.Navigate(itemUrl);
            itemPage.Validate().Price(itemPrice);
            itemPage.ClickBuyNowButton();
            signInPage.ClickContinueAsGuestButton();
            shippingAddressPage.FillShippingInfo(currentClientInfo);
            shippingAddressPage.Validate().Subtotal(itemPrice);
            shippingAddressPage.ClickContinueButton();
            checkoutPage.Validate().Subtotal(itemPrice);
        }
コード例 #3
0
 public ItemPageBuyBehaviour()
 {
     _itemPage = UnityContainerFactory.GetContainer().Resolve <ItemPage>();
 }
コード例 #4
0
 // This version is compatible only with UnityBehaviorEngine.
 public ItemPageNavigationBehaviour(ItemPage itemPage)
 {
     _itemPage = itemPage;
 }
コード例 #5
0
 // This version is compatible only with UnityBehaviorEngine.
 public ItemPageBuyBehaviour(ItemPage itemPage)
 {
     _itemPage = itemPage;
 }
 public ItemPageNavigationBehaviour()
 {
     this.itemPage = PerfectSystemTestsDesign.Base.UnityContainerFactory.GetContainer().Resolve <ItemPage>();
 }
コード例 #7
0
 public ItemPageNavigationBehaviour(string itemUrl)
 {
     this.itemPage = UnityContainerFactory.GetContainer().Resolve <ItemPage>();
     this.itemUrl  = itemUrl;
 }
コード例 #8
0
 public void WhenUserClicksAddToCartButton()
 {
     itemPage = basePage.GetItemPage();
     itemPage.AddToCartButtonVisibility();
     itemPage.ClickAddToCartButton();
 }
コード例 #9
0
 public ItemPageNavigationBehaviour(string itemUrl)
 {
     this.itemPage = AdvancedBehavioursDesignPatternPartTwo.Base.UnityContainerFactory.GetContainer().Resolve <ItemPage>();
     this.itemUrl  = itemUrl;
 }
コード例 #10
0
 public void BuyNow()
 {
     ItemPage.BuyNow();
 }
コード例 #11
0
 public string GetPrice()
 {
     return(ItemPage.Price());
 }
コード例 #12
0
        //public ShippingAddressPage ShippingAddressPage
        //{
        //    get
        //    {
        //        if (_shippingAddressPage == null)
        //        {
        //            _shippingAddressPage = new ShippingAddressPage();
        //        }
        //        return _shippingAddressPage;
        //    }
        //}
        #endregion

        #region ItemPage

        public void SearchItem()
        {
            ItemPage.Navigate();
        }