internal void DeleteSkill() { //Populate the excel data GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); // Refresh the page GlobalDefinitions.driver.Navigate().Refresh(); //Delete Skill try { //Click on skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000); SkillBtn.Click(); //Click on skill to be deleted GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000); SkillToSel.Click(); //Click on Delete skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[3]/span[2]/i", 20000); DeleteSkillBtn.Click(); Base.test.Log(LogStatus.Pass, "Skill deleted successfully"); } catch (Exception ex) { Assert.Fail("Test failed to Delete Skill", ex.Message); Base.test.Log(LogStatus.Fail, "Skill is deleted successfully"); } }
internal void EnterSkill() { //Populate the excel data GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); // Refresh the page GlobalDefinitions.driver.Navigate().Refresh(); //Click on skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000); SkillBtn.Click(); //Click on add new skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/thead/tr/th[3]/div", 10000); AddNewSkillBtn.Click(); //Add new skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "name", 10000); AddSkillBox.Click(); AddSkill.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Skill")); //Add skill level AddSkillLevel.Click(); new SelectElement(AddSkillLevel).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "SkillLevel")); //Click on add skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//input[@value='Add']", 10000); AddSkillBtn.Click(); Base.test.Log(LogStatus.Info, "Added skill successfully"); }
internal void VerifyEditedSkill() { //Populate the excel data GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); // Refresh the page GlobalDefinitions.driver.Navigate().Refresh(); //Verify updated skill try { //Jump to Skill tab //Click on skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000); SkillBtn.Click(); //Verify Skill Level GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[2]", 10000); var lastRowSkillLevel = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[2]")).Text; Assert.That(lastRowSkillLevel, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(3, "SkillLevel"))); Base.test.Log(LogStatus.Pass, "Skill edited verified successfully"); } catch (Exception ex) { Assert.Fail("Test failed to verify updated Skills", ex.Message); Base.test.Log(LogStatus.Fail, "Skill edited is not verified successfully"); } }
internal void EditSkills() { //Populate the excel data GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); // Refresh the page GlobalDefinitions.driver.Navigate().Refresh(); //Click on skill //Click on skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000); SkillBtn.Click(); //Click on skill to be edited GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000); SkillToSel.Click(); //Click on Edit skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[3]/span[1]/i", 10000); EditSkill.Click(); //Edit the skill //Add skill level GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "level", 10000); AddSkillLevel.Click(); new SelectElement(AddSkillLevel).SelectByText(GlobalDefinitions.ExcelLib.ReadData(3, "SkillLevel")); //Click on update GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[1]/tr/td/div/span/input[1]", 10000); UpdateSkillBtn.Click(); Base.test.Log(LogStatus.Info, "Skill edited successfully"); }
internal void EditProfile() { //Global.GlobalDefinitions.wait(20000); //Populate the Excel Sheet //GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); //Click on Edit button AvailabilityTimeEdit.Click(); //Select AvailabilityTime.Click(); //Availability option Full Time AvailabilityTimeOpt.Click(); CommonMethods.test.Log(LogStatus.Info, "Availability updated"); Console.WriteLine("Availability updated"); /* // Actions action = new Actions(GlobalDefinitions.driver); * // action.MoveToElement(AvailabilityTime).Build().Perform(); * Thread.Sleep(1000); * //IList<IWebElement> AvailableTime = AvailabilityTimeOpt.FindElements(By.TagName("div")); * IList<IWebElement> AvailableTime = GlobalDefinitions.driver.FindElements(By.XPath("//select[@name='availabiltyType']/option")); * int count = AvailableTime.Count; * for (int i = 0; i < count; i++) * { * if (AvailableTime[i].Text == GlobalDefinitions.ExcelLib.ReadData(2, "AvailableTime")) * { * AvailableTime[i].Click(); * CommonMethods.test.Log(LogStatus.Info, "Select the available time"); * Console.WriteLine(AvailableTime[i].Text); * Console.WriteLine(count); * * } * }*/ Thread.Sleep(2000); //Availability Edit AvailabilityHoursEdit.Click(); // Availability Hours option AvailabilityHoursDropDown.Click(); //AvailabilityHours ASNeeded AvailabilityHours.Click(); CommonMethods.test.Log(LogStatus.Info, "Hours updated"); Console.WriteLine("Hours updated"); //Salary SalaryEdit.Click(); //Choose the option from salary dropdown SalaryDropdown.Click(); //SalaryOpt-More than 1000 per month SalaryOpt.Click(); CommonMethods.test.Log(LogStatus.Info, "Earn Target updated"); Console.WriteLine("Earn Target updated"); //--------------------------------------------------------- //Click on Add New Language button AddNewLangBtn.Click(); //Enter the Language //AddLangText.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Language")); //Choose Lang ChooseLang.Click(); ChooseLangOpt.Click(); AddLang.Click(); CommonMethods.test.Log(LogStatus.Info, "Added Language successfully"); Console.WriteLine("Added Language successfully"); //----------------------------------------------------------- //Click on Skill Button SkillBtn.Click(); //Click on Add New Skill Button AddNewSkillBtn.Click(); //Enter the skill //AddSkillText.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Skill")); //Click the skill dropdown ChooseSkill.Click(); ChooseSkilllevel.Click(); AddSkill.Click(); CommonMethods.test.Log(LogStatus.Info, "Added Skills successfully"); Console.WriteLine("Added Skills successfully"); //--------------------------------------------------------- //Click on Education Tab EduBtn.Click(); //Add Education AddNewEducation.Click(); //Enter the University //EnterUniversity.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "University")); //Choose Country ChooseCountry.Click(); //Choose Country Level ChooseCountryOpt.Click(); //Choose Title ChooseTitle.Click(); ChooseTitleOpt.Click(); //Enter Degree //Degree.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Degree")); //Year of Graduation DegreeYear.Click(); DegreeYearOpt.Click(); AddEdu.Click(); CommonMethods.test.Log(LogStatus.Info, "Added Education successfully"); Console.WriteLine("Added Education successfully"); //------------------------------------------------- //Click on Certificates Tab CertiBtn.Click(); //Add new Certificate AddNewCerti.Click(); //Enter Certificate Name //EnterCerti.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Certificate")); //Enter Certified from //CertiFrom.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "CertifiedFrom")); //Enter the Year CertiYear.Click(); CertiYearOpt.Click(); AddCerti.Click(); CommonMethods.test.Log(LogStatus.Info, "Added Certificate successfully"); Console.WriteLine("Added Certificate successfully"); //----------------------------------------------------- }
//Enter Profile detail internal void AddProfile() { // Populate the data in excel GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); #region profile details try { // click on availability edit //Thread.Sleep(1000); GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[2]/div/div/div/div/div/div[3]/div/div[2]/div/span/i", 10000); AvailabilityTimeEdit.Click(); // Click on dropdown menu AvailabilityTime.Click(); //Thread.Sleep(1000); GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "availabiltyType", 10000); //select availability time new SelectElement(AvailabilityTime).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "AvailableTime")); Base.test.Log(LogStatus.Info, "Select the available time"); } catch (Exception ex) { Assert.Fail("Test failed to enter Availability Type", ex.Message); } try { //Click on hours edit HourEdit.Click(); //click on dropdownmenu AvailabilityHour.Click(); //choose from dropdown hours Thread.Sleep(1000); new SelectElement(AvailabilityHour).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "Hours")); Base.test.Log(LogStatus.Info, "Select the available time"); } catch (Exception ex) { Assert.Fail("Test failed to enter Availability Hours", ex.Message); } try { //click on Target edit GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[2]/div/div/div/div/div/div[3]/div/div[4]/div/span/i", 10000); SalaryEdit.Click(); //click on Target salary dropdown SalarySelect.Click(); GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "availabiltyTarget", 10000); //select salary new SelectElement(SalarySelect).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "EarnTarget")); Base.test.Log(LogStatus.Info, "Added Target successfully"); } catch (Exception ex) { Assert.Fail("Test failed to enter Earn Target", ex.Message); } //Click on location // Location.Click(); #endregion #region AddLanguage try { //Click on language add new LangBtn.Click(); GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/thead/tr/th[3]/div", 10000); AddNewLangBtn.Click(); //Add new language AddLangText.Click(); ChooseLang.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Language")); //Select language level ChooseLevel.Click(); new SelectElement(ChooseLevel).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "LanguageLevel")); //Add Language GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//input[@value='Add']", 10000); AddLang.Click(); Base.test.Log(LogStatus.Info, "Added Language successfully"); } catch (Exception ex) { Assert.Fail("Test failed to enter/add Language", ex.Message); } #endregion #region AddSkills try { //Click on skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000); SkillBtn.Click(); //Click on add new skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/thead/tr/th[3]/div", 10000); AddNewSkillBtn.Click(); //Add new skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "name", 10000); AddSkillBox.Click(); AddSkill.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Skill")); //Add skill level AddSkillLevel.Click(); new SelectElement(AddSkillLevel).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "SkillLevel")); //Click on add skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//input[@value='Add']", 10000); AddSkillBtn.Click(); Base.test.Log(LogStatus.Info, "Added skill successfully"); } catch (Exception ex) { Assert.Fail("Test failed to enter/add Skills", ex.Message); } #endregion #region Add Education try { //Click on Education button GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[3]", 10000); EducationBtn.Click(); //Click on add new education GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/thead/tr/th[6]/div", 10000); AddNewEducationBtn.Click(); //Choose country GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "country", 10000); SelectCountry.Click(); new SelectElement(SelectCountry).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "Country")); //Choose title GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "title", 10000); SelectTitle.Click(); new SelectElement(SelectTitle).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "Title")); //Choose year GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "yearOfGraduation", 10000); YearOfGraduation.Click(); new SelectElement(YearOfGraduation).SelectByText(GlobalDefinitions.ExcelLib.ReadData(2, "YearOfGraduation")); //Choose institute name GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "instituteName", 10000); InstitName.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "University")); //Choose degree GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "Name", "degree", 10000); Degree.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Degree")); //Click on add education GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//input[@value='Add']", 10000); AddEdu.Click(); Base.test.Log(LogStatus.Info, "Added Education successfully"); } catch (Exception ex) { Assert.Fail("Test failed to enter/add Education", ex.Message); } # endregion #region AddCertification try {
internal void VerifyProfile() { // Populate data saved in Excel GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); // Refresh the page GlobalDefinitions.driver.Navigate().Refresh(); #region Verify profile details //verify language try { //Verify Language Name GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[1]", 10000); LangBtn.Click(); GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000); var lastRowLanguageName = GlobalDefinitions.driver.FindElement(By.XPath("//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[1]")).Text; Assert.That(lastRowLanguageName, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "Language"))); //Verify Language Level GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[2]", 10000); var lastRowLanguageLevel = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[2]")).Text; Assert.That(lastRowLanguageLevel, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "LanguageLevel"))); } catch (Exception ex) { Assert.Fail("Test failed to verify Entering Language", ex.Message); } //verify skill try { //Jump to Skill tab //Click on skill GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000); SkillBtn.Click(); //Verify Skill Name GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000); var lastRowSkillName = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[1]")).Text; Assert.That(lastRowSkillName, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "Skill"))); //Verify Skill Level GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[2]", 10000); var lastRowSkillLevel = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[2]")).Text; Assert.That(lastRowSkillLevel, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "SkillLevel"))); } catch (Exception ex) { Assert.Fail("Test failed to verify Entering Skills", ex.Message); } //verify education try { //Jump to Education tab GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[3]", 10000); EducationBtn.Click(); //Verify Education Country GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000); var lastRowEducationCountry = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[1]")).Text; Assert.That(lastRowEducationCountry, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "Country"))); //Verify Education Name GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[2]", 10000); var lastRowEducationName = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[2]")).Text; Assert.That(lastRowEducationName, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "University"))); //Verify Education Title GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[3]", 10000); var lastRowEducationTitle = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[3]")).Text; Assert.That(lastRowEducationTitle, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "Title"))); //Verify Education Degree GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[4]", 10000); var lastRowEducationDegree = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[4]")).Text; Assert.That(lastRowEducationDegree, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "Degree"))); //Verify Education Graduation Year GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[5]", 10000); var lastRowEducationGraduationYear = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[5]")).Text; Assert.That(lastRowEducationGraduationYear, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "YearOfGraduation"))); } catch (Exception ex) { Assert.Fail("Test failed to verify Entering Education", ex.Message); } //verify certification try { //Jump to Certification tab GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[4]", 10000); CertificationBtn.Click(); //Verify Certificate Name GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[1]", 10000); var lastRowCertificateName = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[1]")).Text; Assert.That(lastRowCertificateName, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "Certificate"))); //Verify Certificate Issuing Place GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[2]", 10000); var lastRowCertificateFrom = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[2]")).Text; Assert.That(lastRowCertificateFrom, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "CertifiedFrom"))); //Verify Certificate Year GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[3]", 10000); var lastRowCertificateYear = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[3]")).Text; Assert.That(lastRowCertificateYear, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "YearOfCertification"))); } catch (Exception ex) { Assert.Fail("Test failed to verify Entering Certification", ex.Message); } //Verify Description try { GlobalDefinitions.WaitForElementVisibility(GlobalDefinitions.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/div/div/div/span", 10000); var description = GlobalDefinitions.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/div/div/div/span")).Text; Assert.That(description, Is.EqualTo(GlobalDefinitions.ExcelLib.ReadData(2, "Description"))); } catch (Exception ex) { Assert.Fail("Test failed to verify Entering Description", ex.Message); } #endregion }