public void Should_Allow_Login_and_Logout() { username = RandomString(); password = RandomString(); var user = CreateUser(username, password, roles: new string[] { "Checkin" }); Open($"{rootUrl}CheckIn/"); WaitForElement("#CheckInApp", 30); Find(name: "username").SendKeys(username); Find(name: "password").SendKeys(password); Find(name: "kiosk").SendKeys("test"); Find(css: "input[type=submit]").Click(); Wait(10); Open($"{rootUrl}CheckIn/"); WaitForElement("#CheckInApp", 30); PageSource.ShouldContain("Enter your phone number"); Open($"{rootUrl}CheckIn/Logout", true); Open($"{rootUrl}CheckIn/"); WaitForElement("#CheckInApp", 30); PageSource.ShouldNotContain("Enter your phone number"); }
public ParsePage VerifyRobotsPresentWithNoIndexNoFollow() { PageSource.ShouldContain("meta name=\"robots\" content=\"NOINDEX, NOFOLLOW\""); PageSource.ShouldNotContain("meta name=\"robots\" content=\"NOINDEX, FOLLOW\""); PageSource.ShouldNotContain("meta name=\"robots\" content=\"INDEX, NOFOLLOW\""); return(this); }
public void Should_Not_Show_Deceased_Person_In_Family_Attendance() { MaximizeWindow(); username = RandomString(); password = RandomString(); var user = CreateUser(username, password, roles: new string[] { "Access", "Edit", "Admin" }); var org = MockOrganizations.CreateOrganization(db, RandomString()); org.RegistrationTypeId = RegistrationTypeCode.RecordFamilyAttendance; db.SubmitChanges(); var family = user.Person.Family; var deceasedPerson = CreatePerson(family); deceasedPerson.DeceasedDate = DateTime.Now.AddYears(-10); db.SubmitChanges(); Login(); Wait(3); Open($"{rootUrl}OnlineReg/{org.OrganizationId}"); Wait(3); PageSource.ShouldContain(user.Person.FirstName); PageSource.ShouldNotContain(deceasedPerson.FirstName); }
public ParsePage VerifyRobotsPresentWithIndexFollow() { PageSource.ShouldContain("meta name=\"robots\" content=\"index, follow\""); //RB: there is an issue with lower case, to be consistent it should be <meta name="robots" content="INDEX, FOLLOW" /> PageSource.ShouldNotContain("meta name=\"robots\" content=\"NOINDEX, NOFOLLOW\""); PageSource.ShouldNotContain("meta name=\"robots\" content=\"NOINDEX, FOLLOW\""); PageSource.ShouldNotContain("meta name=\"robots\" content=\"INDEX, NOFOLLOW\""); return(this); }
public ParsePage VerifyPropertyProfileForSold(string mode, string address) { var propertyProfileUrl = ConfigurationHelper.DomainWebServer + "/property-profile/" + address + "-" + Regex.Match(Url, @"\d+").Value; if (mode == "Sold") { PageSource.ShouldContain(propertyProfileUrl); } else { PageSource.ShouldNotContain(propertyProfileUrl); } return(this); }
public void Should_Hide_Giving_Tab() { SettingUtils.UpdateSetting("HideGivingTabMyDataUsers", "false"); username = RandomString(); password = RandomString(); var user = CreateUser(username, password); Login(); Open($"{rootUrl}Person2/{user.PeopleId}"); WaitForElement(".active:nth-child(2) > a", 10); PageSource.ShouldContain("<a href=\"#giving\" aria-controls=\"giving\" data-toggle=\"tab\">Giving</a>"); SettingUtils.UpdateSetting("HideGivingTabMyDataUsers", "true"); Open($"{rootUrl}Person2/Current"); //refresh page WaitForElement(".active:nth-child(2) > a", 5); PageSource.ShouldNotContain("<a href=\"#giving\" aria-controls=\"giving\" data-toggle=\"tab\">Giving</a>"); SettingUtils.DeleteSetting("HideGivingTabMyDataUsers"); }
private void Toggle_NavTabs_Setting(bool shouldBeVisible) { Open($"{rootUrl}Roles/1"); Find(css: "button[data-target=\"#General\"]").Click(); Wait(0.5); Find(css: "#HideNavTabs + .toggle-group").Parent().Click(); WaitForElement(".snackbar.success"); Open(rootUrl); var navbar = @"<ul class=""nav navbar-nav"">"; if (shouldBeVisible) { PageSource.ShouldContain(navbar); } else { PageSource.ShouldNotContain(navbar); } }
public ParsePage VerifyRelAmp() { PageSource.ShouldNotContain("link rel=\"amphtml\" href=\""); return(this); }
public ParsePage VerifyPreviousLinkNotPresent() { PageSource.ShouldNotContain("link rel=\"prev\""); return(this); }
public ParsePage VerifyNextLinkNotPresent() { PageSource.ShouldNotContain("link rel=\"next\""); return(this); }
public ParsePage VerifyRobotsNotPresent() { PageSource.ShouldNotContain("meta name=\"robots\""); return(this); }
public ParsePage VerifyCanonicalNotPresent() { PageSource.ShouldNotContain("link rel=\"canonical\""); return(this); }
public ParsePage VerifyMetaMobileLinkPresent() { PageSource.ShouldNotContain("link id=\"MetaMobileLink\""); //RB: Checking Metamobile link return(this); }
public ParsePage VerifyTextNotPresent(string text) { PageSource.ShouldNotContain(text); return(this); }