}
}
+ /**
+ * Click on a link and have it open full-page
+ * @param $element
+ * @param string $waitFor
+ */
+ function clickLinkSuppressPopup($element, $waitFor = 'civicrm-footer') {
+ $link = $this->getAttribute($element . '@href');
+ $this->open($link);
+ $this->waitForPageToLoad($this->getTimeoutMsec());
+ if ($waitFor) {
+ $this->waitForElementPresent($waitFor);
+ }
+ }
+
/**
* Call the API on the local server
* (kind of defeats the point of a webtest - see CRM-11889)
// Go for Ckeck Your Editor, Click on Send Mail
$this->click("//a[@id='crm-contact-actions-link']/span");
- //after clicking on 'Send an Email', wait for the text in tinymce editor to load
- $this->clickLink('link=Send an Email', "xpath=//body[@id='tinymce']/p[2]", FALSE);
+ // the other test checks this in a popup, we'll try it full-page here
+ $this->clickLinkSuppressPopup('link=Send an Email', "xpath=//body[@id='tinymce']/p[2]");
$this->click('subject');
$subject = 'Subject_' . substr(sha1(rand()), 0, 8);