Exemple #1
0
 public void AddNewClaimTest()
 {
     driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='*****@*****.**'])[1]/following::input[1]")).Click();
     Thread.Sleep(10000);
     //driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(15000);
     //Thread.Sleep(95000);
     for (int i = 1; i < 3; i++)
     {
         SeleniumSetMethods.Click(driver, "Claims", "Id");
         //driver.FindElement(By.LinkText("Claims")).Click();
         driver.FindElement(By.LinkText("Open Claims")).Click();
         driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(95000);
         driver.FindElement(By.XPath("/html/body/div[1]/div/div/div/div/div[1]/div/div[3]/button")).Click();
         driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(3000);
         //driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Category'])[1]/following::div[4]")).Click();
         driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Allowance'])[1]/following::*[name()='svg'][1]")).Click();
         driver.FindElement(By.Id("react-select-3-option-2")).Click();
         //driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(1000);
         //driver.FindElement(By.Id("react-select-3-option-1")).Click();
         driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Type'])[1]/following::div[5]")).Click();
         driver.FindElement(By.Id("react-select-4-option-2")).Click();
         driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(10000);
         //Thread.Sleep(10000);
         driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='*'])[1]/following::div[4]")).Click();
         driver.FindElement(By.Id("react-select-5-option-2")).Click();
         driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='*'])[2]/following::div[4]")).Click();
         driver.FindElement(By.Id("react-select-6-option-2")).Click();
         driver.FindElement(By.Name("Description")).Click();
         driver.FindElement(By.Name("Description")).Clear();
         driver.FindElement(By.Name("Description")).SendKeys("Testing");
         driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Audit Year'])[1]/following::div[4]")).Click();
         driver.FindElement(By.Id("react-select-7-option-1")).Click();
         driver.FindElement(By.Id("0s")).Click();
         driver.FindElement(By.Id("react-select-8-option-0")).Click();
         driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='AUS | US | All US Locations'])[1]/following::div[11]")).Click();
         driver.FindElement(By.Id("react-select-9-option-346")).Click();
         driver.FindElement(By.Id("0i")).Click();
         //driver.FindElement(By.Id("0i")).Clear();
         Random number = new Random();
         int    amount = number.Next(1500, 2000);
         driver.FindElement(By.Id("0i")).SendKeys("" + amount);
         //driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(3000);
         Thread.Sleep(3000);
         driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Claim Source'])[1]/following::a[1]")).Click();
         Thread.Sleep(95000);
         //driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(950000);
         //driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(95000);
         //UAT
         //driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Alaska/Hawaii/Puerto Rico'])[3]/following::button[1]")).Click();
         // QA
         //driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Alaska/Hawaii/Puerto Rico'])[7]/following::button[1]")).Click();
         //DEV
         //driver.FindElement(By.XPath("(.//*[normalize-space(text()) and normalize-space(.)='Dilution'])[23]/following::button[1]")).Click();
     }
 }
Exemple #2
0
        public void ExecuteSetTest()
        {
            //Title
            SeleniumSetMethods.SelectDropDown("TitleId", "Mr.", PropertyType.Id);

            //Initial
            SeleniumSetMethods.EnterText("Initial", "Execute Automation", PropertyType.Name);

            //Click
            SeleniumSetMethods.Click("Save", PropertyType.Name);
        }
Exemple #3
0
        public void ExecuteGetTest()
        {
            //Set Title
            SeleniumSetMethods.SelectDropDown("TitleId", "Mr.", PropertyType.Id);

            //Set Initial
            SeleniumSetMethods.EnterText("Initial", "Execute Automation", PropertyType.Name);

            //Get Title
            Console.WriteLine("The value from my Title is: " +
                              SeleniumGetMethods.GetTextFromDropDownList("TitleId", PropertyType.Id));

            //Get Initial
            Console.WriteLine("The value from my Initial is: " +
                              SeleniumGetMethods.GetText("Initial", PropertyType.Name));
        }