public static void CreateContact(ApplicationManager app) { ContaktData group = new ContaktData("a1", "a1"); app.Contakts .InitNewContaktCreation() .FillContaktForm(group) .SubmitContaktCreation(); }
public ContaktHelper Modify(int v, ContaktData newData) { manager.Navigator.GoToHomePage(); SelectContakt(v); InitContaktModification(v); FillContaktForm(newData); SubmitContaktModification(); manager.Navigator.GoToMainPage(); return(this); }
public void ContaktModificationTest() { ContaktData newData = new ContaktData("pp", "ss"); if (!app.Contakts.CheckAnyExsists()) { ContaktCreationTests.CreateContact(app); } app.Contakts.Modify(1, newData); }
public void ContaktCreationTest() { OpenHomePage(); Login(new AccountData("admin", "secret")); GoToContaktsPage(); //InitContaktCreation(); ContaktData contakt = new ContaktData("John", "Smith"); FillContaktForm(contakt); SubmitContaktCreation(); OpenHomePage(); //ReturnToContaktsPage(); }
private void FillContaktForm(ContaktData contakt) { driver.FindElement(By.Name("firstname")).Clear(); driver.FindElement(By.Name("firstname")).SendKeys(contakt.Firstname); driver.FindElement(By.Name("lastname")).Clear(); driver.FindElement(By.Name("lastname")).SendKeys(contakt.Lastname); /*driver.FindElement(By.Name("nickname")).Clear(); * driver.FindElement(By.Name("nickname")).SendKeys(nickname); * driver.FindElement(By.Name("group_header")).Click(); * driver.FindElement(By.Name("group_header")).Clear(); * driver.FindElement(By.Name("group_header")).SendKeys(groupheader); * driver.FindElement(By.Name("group_footer")).Click(); * driver.FindElement(By.Name("group_footer")).Clear(); * driver.FindElement(By.Name("group_footer")).SendKeys(groupfooter);*/ }
public ContaktHelper FillContaktForm(ContaktData group) { Type(By.Name("firstname"), group.Firstname); Type(By.Name("middlename"), group.Middlename); Type(By.Name("lastname"), group.Lastname); Type(By.Name("nickname"), group.Nickname); Type(By.Name("title"), group.Title); Type(By.Name("company"), group.Company); Type(By.Name("address"), group.Address); Type(By.Name("home"), group.Home); Type(By.Name("mobile"), group.Mobile); Type(By.Name("work"), group.Work); Type(By.Name("fax"), group.Fax); Type(By.Name("email"), group.Email); Type(By.Name("email2"), group.Email2); Type(By.Name("email3"), group.Email3); Type(By.Name("homepage"), group.Homepage); Type(By.Name("address2"), group.Address2); Type(By.Name("phone2"), group.Phone2); Type(By.Name("notes"), group.Notes); return(this); }