Exemple #1
0
 public void UserHasDetails(UserGridElements elements, UserDetails details)
 {
     elements.MasterToggleDetailsButton.Click();
     Manager.Current.ActiveBrowser.WaitForElement(2500, "CandidateInformation".ToClassIsExpression());
     elements.DetailsUsername.AssertTextEquals(details.Username);
     elements.DetailsName.AssertTextIsContained(details.FirstNameInBulgarian);
     elements.DetailsName.AssertTextIsContained(details.LastNameInBulgarian);
     elements.DetailsBirthDate.AssertTextEquals(details.BirthDate.ToString("dd-MM-yyyy"));
     elements.DetailsGender.AssertTextEquals(details.GenderAssert);
     elements.DetailsOccupation.AssertTextEquals(details.Occupation);
     elements.DetailsCity.AssertTextEquals(details.City);
     elements.DetailsPhone.AssertTextEquals(details.MobilePhone);
     elements.DetailsEmail.AssertTextEquals(details.Email);
     elements.DetailsSkypeName.AssertTextEquals(details.Skype);
     elements.DetailsForumPoints.AssertTextEquals(details.ForumPoints.ToString("F0"));
     elements.DetailsUniversity.AssertTextEquals(details.University);
     elements.DetailsFaculty.AssertTextEquals(details.Faculty);
     elements.DetailsFacultyNumber.AssertTextEquals(details.FacultyNumber);
     elements.DetailsSpecialty.AssertTextEquals(details.Specialty);
     elements.DetailsSchool.AssertTextEquals(details.School);
     elements.DetailsWebsite.AssertTextEquals(details.WebSite);
     elements.DetailsGooglePlus.AssertTextEquals(details.GooglePlus);
     elements.DetailsLinkedIn.AssertTextEquals(details.LinkedIn);
     elements.DetailsTwitter.AssertTextEquals(details.Twitter);
     elements.DetailsFacebook.AssertTextEquals(details.Facebook);
 }
Exemple #2
0
        public string GetFirstUserEmail()
        {
            UserGridElements userRow = this.GetFirstUserGridElements();
            string           email   = userRow.MasterEmail.InnerText;

            return(email);
        }
Exemple #3
0
 public void UserHasDetails(UserGridElements elements, UserDetails details)
 {
     elements.MasterToggleDetailsButton.Click();
     Manager.Current.ActiveBrowser.WaitForElement(2500, "CandidateInformation".ToClassIsExpression());
     elements.DetailsUsername.AssertTextEquals(details.Username);
     elements.DetailsName.AssertTextIsContained(details.FirstNameInBulgarian);
     elements.DetailsName.AssertTextIsContained(details.LastNameInBulgarian);
     elements.DetailsBirthDate.AssertTextEquals(details.BirthDate.ToString("dd-MM-yyyy"));
     elements.DetailsGender.AssertTextEquals(details.GenderAssert);
     elements.DetailsOccupation.AssertTextEquals(details.Occupation);
     elements.DetailsCity.AssertTextEquals(details.City);
     elements.DetailsPhone.AssertTextEquals(details.MobilePhone);
     elements.DetailsEmail.AssertTextEquals(details.Email);
     elements.DetailsSkypeName.AssertTextEquals(details.Skype);
     elements.DetailsForumPoints.AssertTextEquals(details.ForumPoints.ToString("F0"));
     elements.DetailsUniversity.AssertTextEquals(details.University);
     elements.DetailsFaculty.AssertTextEquals(details.Faculty);
     elements.DetailsFacultyNumber.AssertTextEquals(details.FacultyNumber);
     elements.DetailsSpecialty.AssertTextEquals(details.Specialty);
     elements.DetailsSchool.AssertTextEquals(details.School);
     elements.DetailsWebsite.AssertTextEquals(details.WebSite);
     elements.DetailsGooglePlus.AssertTextEquals(details.GooglePlus);
     elements.DetailsLinkedIn.AssertTextEquals(details.LinkedIn);
     elements.DetailsTwitter.AssertTextEquals(details.Twitter);
     elements.DetailsFacebook.AssertTextEquals(details.Facebook);
 }
Exemple #4
0
        public string GetFirstUserId()
        {
            UserGridElements userRow = this.GetFirstUserGridElements();
            string           id      = userRow.MasterId.InnerText;

            return(id);
        }
Exemple #5
0
        public string GetFirstUserUsername()
        {
            UserGridElements userRow  = this.GetFirstUserGridElements();
            string           username = userRow.MasterUsername.InnerText;

            return(username);
        }
Exemple #6
0
        public UserGridElements GetFirstUserGridElements()
        {
            this.WaitForGridToLoad();
            var userRow = new UserGridElements(this.Elements.GetGridRowByRowIndex(1));

            return(userRow);
        }
Exemple #7
0
        public void OpenFirstUserEditPopUp()
        {
            this.WaitForGridToLoad();
            UserGridElements userRow = this.GetFirstUserGridElements();

            userRow.MasterEditUser.Click();
        }
Exemple #8
0
        public void OpenEditPopUp(string username)
        {
            this.WaitForGridToLoad();
            var userRow = new UserGridElements(username);

            userRow.MasterEditUser.Click();
        }
Exemple #9
0
 public void DeleteUser(string username)
 {
     Manager.Current.DialogMonitor.AddDialog(new AlertDialog(Manager.Current.ActiveBrowser, DialogButton.OK));
     Manager.Current.DialogMonitor.Start();
     this.WaitForGridToLoad();
     var userRow = new UserGridElements(username);
     userRow.MasterDeleteUser.Click();
 }
Exemple #10
0
        public void DeleteUser(string username)
        {
            Manager.Current.DialogMonitor.AddDialog(new AlertDialog(Manager.Current.ActiveBrowser, DialogButton.OK));
            Manager.Current.DialogMonitor.Start();
            this.WaitForGridToLoad();
            var userRow = new UserGridElements(username);

            userRow.MasterDeleteUser.Click();
        }
Exemple #11
0
        public void EditFirstUser(UserDetails userDetails)
        {
            this.OpenFirstUserEditPopUp();
            string username = this.GetFirstUserUsername();

            this.EditPopup.Validator.EditUserPopupIsOpened(username);
            this.EditPopup.EnterUserDetails(userDetails);
            this.EditPopup.Elements.UpdateButton.Click();
            UserGridElements userGridElements = this.GetFirstUserGridElements();

            userDetails.ForumPoints += 1;
            this.Validator.UserHasDetails(userGridElements, userDetails);
        }
Exemple #12
0
 public UserGridElements GetFirstUserGridElements()
 {
     this.WaitForGridToLoad();
     var userRow = new UserGridElements(this.Elements.GetGridRowByRowIndex(1));
     return userRow;
 }
Exemple #13
0
 public void OpenEditPopUp(string username)
 {
     this.WaitForGridToLoad();
     var userRow = new UserGridElements(username);
     userRow.MasterEditUser.Click();
 }