Exemplo n.º 1
0
        public void ThenButtonSubmitIsEnabledInCreatePaymentForm()
        {
            string temp = "{\"PaymentId\":0,\"CardOwnerName\":\"John Doe\",\"CardNumber\":\"1234123412341234\",\"ExpirationDate\":\"11 / 44\",\"CVV\":\"123\"}";

            mockServicesContext.PaymentDetailsMock.SetupPost(temp);

            var page = new PaymentDetailRegisterPage(webBrowser);

            Assert.IsTrue(page.btnSubmit.Enabled, "Button 'Submit' is not enabled in CreatePayment form.");
        }
Exemplo n.º 2
0
        public void WhenUserEntersInCreatePaymentForm(Table table)
        {
            var payment = table.CreateInstance <PaymentDetail>();
            var page    = new PaymentDetailRegisterPage(webBrowser);

            page.txtCardOwnerName.Click();
            page.txtCardOwnerName.SendKeys(payment.CardOwnerName);

            page.txtCardNumber.SendKeys(payment.CardNumber);

            page.txtExpirationDate.Click();
            page.txtExpirationDate.SendKeys(payment.ExpirationDate);

            page.txtCvv.Click();
            page.txtCvv.SendKeys(payment.CVV);

            paymentDetailsContext.PaymentBeingCreated = payment;
        }
Exemplo n.º 3
0
        public void WhenUserClicksButtonSubmitInCreatePaymentForm()
        {
            var page = new PaymentDetailRegisterPage(webBrowser);

            page.btnSubmit.Click();
        }