public static void PO_AdvertiseJobs()
        {
            ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html/body/div[5]/div/div[5]/a[1]");
            Thread.Sleep(1500);

            //navigate to Owners>Properties
            ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html[1]/body[1]/div[1]/div[1]/div[2]/div[1]");
            Thread.Sleep(1500);
            ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html[1]/body[1]/div[1]/div[1]/div[2]/div[1]/div[1]/a[4]");


            //Checking the right page
            Assert.AreEqual("My Advertised Jobs", Driver.driver.Title);
            Base.test = Base.extent.StartTest("In My Advertised Jobs  page");
            Thread.Sleep(1500);

            //Adding new job
            ExtendMethods.ButtonClick(Driver.driver, "XPath", "/ html[1] / body[1] / div[2] / div[1] / div[1] / div[2] / div[1] / div[2] / a[1]");


            ExtendMethods.TextBox(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[1]/form[1]/div[1]/div[1]/div[1]/div[2]/div[1]/input[1]", "Gas Geyser Installation");
            Thread.Sleep(1500);
            ExtendMethods.TextBox(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[1]/form[1]/div[1]/div[1]/div[1]/div[3]/div[1]/input[1]", "600");
            Thread.Sleep(1500);

            ExtendMethods.TextBox(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[1]/form[1]/div[1]/div[1]/div[2]/div[1]/textarea[1]", "Need Urgent installation of gas geyser");
            ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[1]/form[1]/div[1]/div[3]/div[1]/div[1]/button[1]");
            Base.test = Base.extent.StartTest("Job added succesfully");
        }
        public void GivenIHaveLoggedInWithValidServiceSupplier()
        {
            Base.Init();
            LoginPage obj = new LoginPage();

            obj.MyDoSomethingMethod(LoginPage.MyEnumUserLogin.Service_Supp);
            ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html/body/div[5]/div/div[5]/a[1]");
        }
Example #3
0
 public static void SS_ApplyJob()
 {
     //ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html/body/div[5]/div/div[5]/a[1]");
     Thread.Sleep(1500);
     ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html[1]/body[1]/div[1]/div[1]/div[2]/a[3]");
     ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[1]/div[3]/div[1]/div[3]/div[1]/div[1]/button[1]");
     //Console.WriteLine(Driver.driver.FindElement(By.XPath("/html[1]/body[1]/div[2]/div[1]/div[2]/form[1]/fieldset[1]/div[2]/div[1]/div[1]/div[1]/div[3]/div[1]/div[1]/h4[1]")).Text);
     Thread.Sleep(1500);
     ExtendMethods.TextBox(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[2]/form[1]/fieldset[1]/div[3]/div[1]/div[1]/input[1]", "550");
     ExtendMethods.TextBox(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[2]/form[1]/fieldset[1]/div[3]/div[2]/div[1]/textarea[1]", "I Will Fix This Jon ASAP");
     Thread.Sleep(1500);
     ExtendMethods.ButtonClick(Driver.driver, "XPath", "/html[1]/body[1]/div[2]/div[1]/div[2]/form[1]/fieldset[1]/div[3]/div[4]/button[1]");
     Base.test = Base.extent.StartTest("Quote submitted successfully");
 }