$this->_ut->waitForElementPresent('css=td.crm-mailing-name');
// This should select the first "Report" link in the table, which is sorted by Completion Date descending, so in theory is the most recent email. Not sure of a more robust way at the moment.
- $this->_ut->click('xpath=//tr[contains(@id, "crm-mailing_")]//a[text()="Report"]');
+ $this->_ut->clickLink('xpath=//tr[contains(@id, "crm-mailing_")]//a[text()="Report"]');
// Also not sure how robust this is, but there isn't a good
// identifier for this link either.
$this->_ut->waitForElementPresent('xpath=//a[contains(text(), "View complete message")]');
- $this->_ut->click('xpath=//a[contains(text(), "View complete message")]');
-
- $this->_ut->waitForPopUp(NULL, 30000);
- $this->_ut->selectPopUp(NULL);
+ $this->_ut->clickLinkSuppressPopup('xpath=//a[contains(text(), "View complete message")]', NULL);
/*
* FIXME:
*
*/
//$msg = $this->_ut->getHtmlSource();
$msg = $this->_ut->getBodyText();
- $this->_ut->close();
- $this->_ut->selectWindow(NULL);
}
else {
* @return ezcMail
*/
private function convertToEzc($msg) {
- $set = new ezcMailVariableSet($msg);
+ $set = new ezcMailVariableSet($msg);print_r($msg);
$parser = new ezcMailParser();
$mail = $parser->parseMail($set);
$this->_ut->assertNotEmpty($mail, 'Cannot parse mail');
$this->type('billing_street_address-5', '234 Lincoln Ave');
$this->type('billing_city-5', 'San Bernadino');
- $this->select('billing_country_id-5', 'value=1228');
- $this->click('billing_state_province_id-5');
- $this->waitForVisible('billing_state_province_id-5');
- $this->select('billing_state_province_id-5', 'label=California');
+ $this->select2('billing_country_id-5', 'United States');
+ $this->select2('billing_state_province_id-5', 'California');
$this->type('billing_postal_code-5', '93245');
return array($firstName, $middleName, $lastName);
$this->waitForElementPresent("xpath=//div[@class='dataTables_wrapper no-footer']//table/tbody/tr[2]/td[8]/span/a[text()='View']");
// click through to the Activity view screen
- $this->click("xpath=//div[@class='dataTables_wrapper no-footer']//table/tbody/tr[2]/td[8]/span/a[text()='View']");
- $this->waitForElementPresent('_qf_Activity_cancel-bottom');
+ $this->clickLinkSuppressPopup("xpath=//div[@class='dataTables_wrapper no-footer']//table/tbody/tr[2]/td[8]/span/a[text()='View']", '_qf_Activity_cancel-bottom');
// parse URL to grab the activity id
// pass id back to any other tests that call this class
$this->webtestAddCreditCardDetails();
- // since country is not pre-selected for offline mode
- $this->select("billing_country_id-5", "label=United States");
- //wait for states to populate the select box
- // Because it tends to cause problems, all uses of sleep() must be justified in comments
- // Sleep should never be used for wait for anything to load from the server
- // Justification for this instance: FIXME
- sleep(2);
- $this->click('billing_state_province_id-5');
$this->webtestAddBillingDetails($firstName, NULL, $lastName);
- $this->click("_qf_Membership_upload-bottom");
- $this->waitForPageToLoad($this->getTimeoutMsec());
+ $this->clickLink("_qf_Membership_upload-bottom");
// Use Find Members to make sure membership exists
$this->openCiviPage("member/search", "reset=1", "member_end_date_high");
$this->type("sort_name", "$firstName $lastName");
$this->click("member_test");
$this->clickLink("_qf_Search_refresh", "xpath=//div[@id='memberSearch']/table/tbody/tr[1]/td[11]/span/a[text()='View']");
- $this->click("xpath=//div[@id='memberSearch']/table/tbody/tr[1]/td[11]/span/a[text()='View']");
- $this->waitForElementPresent("_qf_MembershipView_cancel-bottom");
+ $this->clickAjaxLink("xpath=//div[@id='memberSearch']/table/tbody/tr[1]/td[11]/span/a[text()='View']", "_qf_MembershipView_cancel-bottom");
// View Membership Record
$verifyData = array(
preg_quote($value)
);
}
- $this->waitForElementPresent("_qf_MembershipView_cancel-bottom");
}
}