I am trying to provide a confirmation message that the record has been updated successfully.
The HTML is:
<div class="hide">
<div class="fullRow">
<div class="notice success">
The user record has been updated.
<a href="#close" class="icon-remove"/>
</div>
The C# code that I am using is:
Assert.IsTrue(UserUpdateAdmin.IsAt, "Fialed to Update");
The UserUpdateAdmin class contains the following:
public class UserUpdateAdmin
{
public static bool IsAt
{
get
{
var h1 = Driver.Instance.FindElements(By.ClassName("notice.success"));
if (h1.Count > 0)
return true;
return false;
}
It is throwing an exception: An exception of type
'Microsoft.VisualStudio.TestTools.UnitTesting.AssertFailedException' occurred in Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll but was not handled in user code
Additional information: Assert.IsTrue failed. Failed to Update