$this->waitForElementPresent('_qf_Group_cancel-bottom');
$this->type('title', $profileTitle);
$this->click('_qf_Group_next-bottom');
+ $this->waitForPageToLoad($this->getTimeoutMsec());
- $this->waitForElementPresent('_qf_Field_cancel-bottom');
+ $this->waitForElementPresent("xpath=//a/span[text()='Add Field']");
+ $this->click("xpath=//a/span[text()='Add Field']");
+ $this->waitForElementPresent("field_name[0]");
//$this->assertTrue($this->isTextPresent("Your CiviCRM Profile '{$profileTitle}' has been added. You can add fields to this profile now."));
foreach ($profileFields as $field) {
$this->waitForElementPresent('label');
$this->type("id=label", $field['label']);
$this->click("id=_qf_Field_next_new-top");
- $this->waitForPageToLoad($this->getTimeoutMsec());
+ $this->waitForElementPresent("xpath=//select[@id='field_name_1'][@style='display: none;']");
//$this->assertTrue($this->isTextPresent("Your CiviCRM Profile Field '" . $field['name'] . "' has been saved to '" . $profileTitle . "'. You can add another profile field."));
}
}
$this->waitForText('crm-notification-container', "Your CiviCRM Profile '{$profileTitle}' has been added. You can add fields to this profile now.");
//Add email field to profile
+ $this->click("xpath=//a/span[text()='Add Field']");
+ $this->waitForElementPresent("field_name[0]");
$this->click('field_name[0]');
$this->select('field_name[0]', 'value=Contact');
$this->click("//option[@value='Contact']");
//click on save
$this->click('_qf_Field_next_new-top');
- $this->waitForPageToLoad($this->getTimeoutMsec());
+ $this->waitForText('crm-notification-container', "Your CiviCRM Profile Field 'Email' has been saved to '$profileTitle'.");
+ $this->waitForText('crm-notification-container', 'You can add another profile field.');
//Add email field to profile
$this->click('field_name[0]');
//click on save
$this->click('_qf_Field_next');
- $this->waitForPageToLoad($this->getTimeoutMsec());
+ $this->waitForElementPresent("xpath=//div[@id='field_page']/div/a[4]/span");
//now use profile create mode for group subscription
$this->click("xpath=//div[@id='field_page']/div/a[4]/span");
* @param $profileTitle
*/
function _testdeleteProfile($profileTitle) {
- $this->waitForElementPresent("xpath=//div[@id='user-profiles']/div/div/table/tbody//tr/td/span[text() = '$profileTitle']/../../td[7]/span[2][text()='more']/ul/li[4]/a[text()='Delete']");
- $this->click("xpath=//div[@id='user-profiles']/div/div/table/tbody//tr/td/span[text() = '$profileTitle']/../../td[7]/span[2][text()='more']/ul/li[4]/a[text()='Delete']");
+ $this->waitForElementPresent("xpath=//div[@id='user-profiles']/div/div/table/tbody//tr/td/span[text() = '$profileTitle']/../../td[7]/span[2][text()='more']/ul/li[5]/a[text()='Delete']");
+ $this->click("xpath=//div[@id='user-profiles']/div/div/table/tbody//tr/td/span[text() = '$profileTitle']/../../td[7]/span[2][text()='more']/ul/li[5]/a[text()='Delete']");
$this->waitForElementPresent('_qf_Group_next-bottom');
$this->click('_qf_Group_next-bottom');
$this->waitForElementPresent('newCiviCRMProfile-bottom');
//click on save
$this->click('_qf_Group_next-bottom');
$this->waitForPageToLoad($this->getTimeoutMsec());
+ $this->waitForElementPresent("xpath=//a/span[text()='Add Field']");
//check for profile create
$this->waitForText('crm-notification-container', "Your CiviCRM Profile '{$profileTitle}' has been added. You can add fields to this profile now.");
$profileId = $this->urlArg('gid');
// Add Last Name field.
+ $this->click("xpath=//a/span[text()='Add Field']");
+ $this->waitForElementPresent("field_name[0]");
$this->click('field_name[0]');
$this->select('field_name[0]', 'value=Individual');
$this->click('field_name[1]');
$this->click('in_selector');
// click on save
$this->click('_qf_Field_next_new-bottom');
- $this->waitForPageToLoad($this->getTimeoutMsec());
//check for field add
$this->waitForText('crm-notification-container', "Your CiviCRM Profile Field 'Last Name' has been saved to '$profileTitle'.");
$this->waitForText('crm-notification-container', 'You can add another profile field.');
$this->click('in_selector');
// click on save
$this->click('_qf_Field_next_new-bottom');
- $this->waitForPageToLoad($this->getTimeoutMsec());
//check for field add
$this->waitForText('crm-notification-container', "Your CiviCRM Profile Field 'Email' has been saved to '$profileTitle'.");
$this->waitForText('crm-notification-container', 'You can add another profile field.');
$this->select('visibility', 'value=Public Pages');
$this->click('is_searchable');
$this->click('in_selector');
- $this->clickLink('_qf_Field_next_new-bottom');
+ $this->clickLink('_qf_Field_next_new-bottom', 'field_name[0]', FALSE);
+ $this->waitForElementPresent("xpath=//select[@id='field_name_1'][@style='display: none;']");
// Add state, country and county field
$this->click('field_name[0]');
$this->click('is_searchable');
$this->click('in_selector');
// click on save and new
- $this->clickLink('_qf_Field_next_new-bottom');
+ $this->clickLink('_qf_Field_next_new-bottom', 'field_name[0]', FALSE);
+ $this->waitForElementPresent("xpath=//select[@id='field_name_1'][@style='display: none;']");
$this->click('field_name[0]');
$this->select('field_name[0]', 'value=Contact');
$this->click('is_searchable');
$this->click('in_selector');
// click on save and new
- $this->clickLink('_qf_Field_next_new-bottom');
+ $this->clickLink('_qf_Field_next_new-bottom', 'field_name[0]', FALSE);
+ $this->waitForElementPresent("xpath=//select[@id='field_name_1'][@style='display: none;']");
$this->click('field_name[0]');
$this->select('field_name[0]', 'value=Contact');
$this->click('in_selector');
// click on save
- $this->clickLink('_qf_Field_next-bottom', "xpath=//div[@id='field_page']/div[1]/a[4]/span[text()='Use (create mode)']");
+ $this->clickLink('_qf_Field_next-bottom', "xpath=//div[@id='field_page']/div[1]/a[4]/span[text()='Use (create mode)']", FALSE);
$uselink = explode('?', $this->getAttribute("xpath=//*[@id='field_page']/div[1]/a[4]@href"));
$this->openCiviPage('profile/create', "$uselink[1]", '_qf_Edit_cancel');
$this->select('county-Primary', "Alameda");
// Select Custom option
- $this->click('CIVICRM_QFID_Edu_2');
+ $this->select('custom_1', 'Education');
$this->click('_qf_Search_refresh');
$this->waitForPageToLoad($this->getTimeoutMsec());