//------------------------------------------------------------------------------------------- public void Register(string emailAddress, string userName, string password, bool checkingOut) { WeavverTest wt = new WeavverTest(); // enter user info wt.SetControlValue(By.Id("Content_RegisterUser_Wizard1_ctl09_FirstName"), "John"); wt.SetControlValue(By.Id("Content_RegisterUser_Wizard1_ctl09_LastName"), "Doe"); wt.SetControlValue(By.Id("Content_RegisterUser_Wizard1_ctl09_OrganizationName"), "Sprockets, Inc."); wt.SetControlValue(By.Id("Content_RegisterUser_Wizard1_ctl09_EmailAddress"), emailAddress); wt.SetControlValue(By.Id("Content_RegisterUser_Wizard1_ctl09_UserName"), userName); wt.SetControlValue(By.Id("Content_RegisterUser_Wizard1_ctl09_Password"), password); wt.webDriver.FindElement(By.Name("ctl00$Content$RegisterUser$Wizard1$__CustomNav0$Next")).Click(); wt.WaitForPageLoad(); if (!checkingOut) { // bypass captcha test wt.SetControlValue(By.Id("recaptcha_response_field"), Helper.GetAppSetting("recaptcha_bypasskey")); wt.webDriver.FindElement(By.Id("Content_RegisterUser_Wizard1_ctl10_Register")).Click(); // download e-mail/activate account Activate(); } }