From: Ravish Nair Date: Fri, 22 Mar 2013 10:28:43 +0000 (+0530) Subject: -- webtest fixes X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=ef72146d54535b4810625b9342fea570323bf88b;p=civicrm-core.git -- webtest fixes --- diff --git a/tests/phpunit/WebTest/Contact/SignatureTest.php b/tests/phpunit/WebTest/Contact/SignatureTest.php index b0b1969489..e6d3c04675 100644 --- a/tests/phpunit/WebTest/Contact/SignatureTest.php +++ b/tests/phpunit/WebTest/Contact/SignatureTest.php @@ -67,7 +67,8 @@ class WebTest_Contact_SignatureTest extends CiviSeleniumTestCase { // Go for Ckeck Your Editor, Click on Send Mail $this->click("//a[@id='crm-contact-actions-link']/span"); - $this->clickLink('link=Send an Email', 'subject'); + //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]"); $this->click('subject'); $subject = 'Subject_' . substr(sha1(rand()), 0, 8); diff --git a/tests/phpunit/WebTest/Event/AddEventTest.php b/tests/phpunit/WebTest/Event/AddEventTest.php index 6ee243ad60..83d78d1e6f 100644 --- a/tests/phpunit/WebTest/Event/AddEventTest.php +++ b/tests/phpunit/WebTest/Event/AddEventTest.php @@ -302,8 +302,7 @@ class WebTest_Event_AddEventTest extends CiviSeleniumTestCase { $this->waitForElementPresent("_qf_Fee_upload-bottom"); $this->assertChecked('is_pay_later'); $this->click("CIVICRM_QFID_0_is_monetary"); - $this->click("_qf_Fee_upload-bottom"); - $this->waitForElementPresent("_qf_Fee_upload-bottom"); + $this->clickLink("_qf_Fee_upload-bottom", "_qf_Fee_upload-bottom"); //check if pay later option is disabled $this->click('CIVICRM_QFID_1_is_monetary');