public void ThenIShouldAbleToUpdateMyExperienceInformation() { Driver.Navigate().GoToUrl(new Uri(Settings.AUT + "profile")); ProfilePage profilePage = new ProfilePage(Driver); profilePage.AddExperience(); try { var spanTex = Driver.FindElement(By.XPath("//div[@class='ant-message-custom-content ant-message-success'][contains(.,'Added record')]")).Text; Assert.IsNotEmpty(spanTex); } catch (Exception e) { _ = e.Message; } profilePage.EditExperience(); try { var spanTex = Driver.FindElement(By.XPath("(//span[contains(.,'Updated Experience')])[2]")).Text; Assert.IsNotEmpty(spanTex); } catch (Exception e) { _ = e.Message; } profilePage.DeleteExperience(); try { var spanTex = Driver.FindElement(By.XPath("(//span[contains(.,'Deleted')])[2]")).Text; Assert.IsNotEmpty(spanTex); } catch (Exception e) { _ = e.Message; } }