public void EndtoEnd() { // Creates a toggle for the given test, adds all log events under it test = extent.StartTest("Add Skill Test"); // Create an class and object to call the method ShareSkill obj = new ShareSkill(); obj.AddSkill(); obj.EditSkill(); obj.DeleteSkill(); }
public void AddValidSkill() { // Creates a toggle for the given test, adds all log events under it test = extent.StartTest("Save a valid skill in field"); // Call the Share Skill method ShareSkill skill = new ShareSkill(); skill.AddSkill(); // Verify if add the skill successfully and navigate to Manage Listing Assert.IsNotNull(GlobalDefinitions.driver.FindElement(By.XPath("//a[contains(text(),'Manage Listings')]"))); }
public void AddSkill() { ShareSkill AddShareSkill = new ShareSkill(); AddShareSkill.AddSkill(); //Thread.Sleep(2000); try { string ExpectedMsg = "Service Listing Added successfully"; GlobalDefinitions.wait(10); string ActulaMsg = AddShareSkill.SkillAddedSuccessMsg.Text; GlobalDefinitions.wait(10); Assert.AreEqual(ExpectedMsg, ActulaMsg); Console.WriteLine(ExpectedMsg); } catch (NoSuchElementException) { Console.Write("Skill Add element not found"); } }