Esempio n. 1
0
        public void HomepageUITest()
        {
            test = extent.CreateTest("HomepageUITest", "Test includes verification of UI elements in Home Page");
            var LoginPage    = new LoginPage();
            var HomePage     = new HomePage();
            var ContactPage  = new ContactUsPage();
            var AboutPage    = new AboutPage();
            var NOrderPage   = new NewOrderPage();
            var ManageUser   = new ManageUsersPage();
            var ManageOrders = new ManageOrdersPage();

            LoginPage.Login(LoginPage.UserName, "*****@*****.**", LoginPage.Password, "July012018", LoginPage.LoginInBtn, LoginPage.Last10RequestsTitle);
            BasicMethods.ClickBtn(HomePage.HomeTab);
            log.Info("In Home Page Screen");
            //  BasicMethods.GetLocation(HomePage.COTLink);
            // BasicMethods.GetSize(HomePage.COTLink);
            Validations.validateTitle("Home - Chemical Ordering Tool");
            BasicMethods.CheckImage(HomePage.HomePageMyLogo);
            BasicMethods.checkWebsite();
            BasicMethods.VerifyText(HomePage.COTBanner1, "Welcome To The");
            BasicMethods.VerifyText(HomePage.COTBanner2, "Chemical Ordering Tool");
            BasicMethods.VerifyText(HomePage.Last10RequestsHeader, "Last 10 Requests");
            HomePage.TestThirdPartyToolsLink(HomePage.DolphinBtn, "Comply Plus");
            HomePage.TestThirdPartyToolsLink(HomePage.SigmaAldrichBtn, "MilliporeSigma | United States");
            HomePage.TestThirdPartyToolsLink(HomePage.FedexBtn, "Tracking | FedEx Canada");
            HomePage.TestThirdPartyToolsLink(HomePage.FisherScientificBtn, "Fisher Scientific: Lab Equipment and Supplies");
            HomePage.TestThirdPartyToolsLink(HomePage.GoogleSearchBtn, "Google");
            HomePage.TestThirdPartyToolsLink(HomePage.ClassWWToolBtn, "WW-Class - Classification Online Request Form");
            HomePage.TestMainTabs(NOrderPage.OrderTab, "Order Request - Chemical Ordering Tool");
            HomePage.TestMainTabs(ManageOrders.ManageOrdersTab, "Manage Orders - Chemical Ordering Tool");
            ManageUser.SelectManageUsersTab();
            BasicMethods.ClickBtn(HomePage.HomeBtn);
            HomePage.TestMainTabs(HomePage.HomeTab, "Home - Chemical Ordering Tool");
            HomePage.TestMainTabs(AboutPage.AboutTab, "About - Chemical Ordering Tool");
            HomePage.TestMainTabs(ContactPage.ContactTab, "Contact - Chemical Ordering Tool");
            HomePage.TestThirdPartyToolsLink(HomePage.ChemicalWasteCollectionRequestFormLink, "HP San Diego - Chemical Waste Collection and Container Request Form - Formstack");
            HomePage.TestThirdPartyToolsLink(HomePage.InkChemicalRequestFormLink, "HP San Diego - Ink Pour, Chemical, Gas, Nitrogen Request Form - Formstack");
            HomePage.TestThirdPartyToolsLink(HomePage.ReturnToStockFormLink, "HP San Diego - Return to Stock or Scrap Form - Formstack");
            HomePage.TestThirdPartyToolsLink(HomePage.InventoryRequestFormLink, "HP San Diego - Inventory Request Form - Formstack");
        }