Ejemplo n.º 1
0
        public void ThenISeeOrderByOrderNumber(string orderNumber)
        {
            DBHelper dbHelper  = new DBHelper();
            var      orderData = dbHelper.getOrderDataByOrderNumber(orderNumber);
            SearchByOrderNumberPage searchByOrderNumberPage = new SearchByOrderNumberPage();

            Tools.WaitElementByClassName(searchByOrderNumberPage.OrderItemClassName);
            Assert.AreEqual(searchByOrderNumberPage.getCreatedOnDate(), orderData["createdOn"]);
            Assert.AreEqual(searchByOrderNumberPage.getOrderNumber(), orderNumber);
            Assert.AreEqual(searchByOrderNumberPage.getFIO(), orderData["lastName"] + ' ' + orderData["firstName"] + ' ' + orderData["middleName"]);
            Assert.AreEqual(searchByOrderNumberPage.getEmailAddress(), orderData["emailAddress"]);
            Assert.AreEqual(searchByOrderNumberPage.getCellPhoneNumber(), orderData["cellPhoneNumber"]);
            //ScenarioContext.Current.Pending();
        }
Ejemplo n.º 2
0
        public void ThenISeeOrdersByExternalSampleNumber(string externalSampleNumber, string dateFromStr, string dateToStr)
        {
            DBHelper dbHelper  = new DBHelper();
            DateTime dateFrom  = DateTime.ParseExact(dateFromStr, "dd/MM/yyyy", null);
            DateTime dateTo    = DateTime.ParseExact(dateToStr, "dd/MM/yyyy", null);
            var      orderData = dbHelper.getOrderDataByExternalSampleNumber(externalSampleNumber, dateFrom, dateTo);
            SearchByOrderNumberPage searchByOrderNumberPage = new SearchByOrderNumberPage();

            Tools.WaitElementByClassName(searchByOrderNumberPage.OrderItemClassName);
            Assert.AreEqual(searchByOrderNumberPage.getCreatedOnDate(), orderData["createdOn"]);
            Assert.AreEqual(searchByOrderNumberPage.getOrderNumber(), orderData["orderNumber"]);
            Assert.AreEqual(searchByOrderNumberPage.getFIO(), orderData["lastName"] + ' ' + orderData["firstName"] + ' ' + orderData["middleName"]);
            Assert.AreEqual(searchByOrderNumberPage.getEmailAddress(), orderData["emailAddress"]);
            Assert.AreEqual(searchByOrderNumberPage.getCellPhoneNumber(), orderData["cellPhoneNumber"]);
            //ScenarioContext.Current.Pending();
        }