From 52b7da1c8b04c0cbf131e734d311c466dde8ea50 Mon Sep 17 00:00:00 2001 From: Web Access Date: Thu, 31 Dec 2015 18:43:18 +0530 Subject: [PATCH] Webtets Fixes --- .../WebTest/Contribute/OnlineRecurContributionTest.php | 4 ++-- tests/phpunit/WebTest/Contribute/StandaloneAddTest.php | 4 ++-- .../Contribute/UpdateBatchPendingContributionTest.php | 5 +++-- tests/phpunit/WebTest/Event/AddPricesetTest.php | 4 ++-- tests/phpunit/WebTest/Event/ParticipantCountTest.php | 2 +- 5 files changed, 10 insertions(+), 9 deletions(-) diff --git a/tests/phpunit/WebTest/Contribute/OnlineRecurContributionTest.php b/tests/phpunit/WebTest/Contribute/OnlineRecurContributionTest.php index 49d870d604..8632ed1a6b 100644 --- a/tests/phpunit/WebTest/Contribute/OnlineRecurContributionTest.php +++ b/tests/phpunit/WebTest/Contribute/OnlineRecurContributionTest.php @@ -133,8 +133,8 @@ class WebTest_Contribute_OnlineRecurContributionTest extends CiviSeleniumTestCas $this->click("contribution_test"); $this->click("_qf_Search_refresh"); - $this->waitForElementPresent('css=#contributionSearch table tbody tr td span a.action-item:first-child'); - $this->click('css=#contributionSearch table tbody tr td span a.action-item:first-child'); + $this->waitForElementPresent('css=#contributionSearch table tbody tr td a.action-item:first-child'); + $this->click('css=#contributionSearch table tbody tr td a.action-item:first-child'); $this->waitForElementPresent("_qf_ContributionView_cancel-bottom"); // View Recurring Contribution Record diff --git a/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php b/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php index 10b32d45c4..0b172c0955 100644 --- a/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php +++ b/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php @@ -142,13 +142,13 @@ class WebTest_Contribute_StandaloneAddTest extends CiviSeleniumTestCase { $this->waitForText("crm-notification-container", "The contribution record has been saved."); // verify if Membership is created - $this->waitForElementPresent("xpath=//table[@class='selector row-highlight']//tbody/tr[1]/td[8]/span//a[text()='View']"); + $this->waitForElementPresent("xpath=//form[@class='CRM_Contribute_Form_Search crm-search-form']//div[2]table[@class='selector row-highlight']//tbody/tr[1]/td[8]/span//a[text()='View']"); $contriID = $this->urlArg('id', $this->getAttribute("xpath=//table[@class='selector row-highlight']//tbody/tr[1]/td[8]/span//a[text()='Edit']@href")); $contactID = $this->urlArg('cid', $this->getAttribute("xpath=//table[@class='selector row-highlight']//tbody/tr[1]/td[8]/span//a[text()='Edit']@href")); //click through to the Membership view screen - $this->click("xpath=//table[@class='selector row-highlight']//tbody/tr[1]/td[8]/span//a[text()='View']"); + $this->click("xpath=//form[@class='CRM_Contribute_Form_Search crm-search-form']//div[2]table[@class='selector row-highlight']//tbody/tr[1]/td[8]/span//a[text()='View']"); $this->waitForElementPresent("_qf_ContributionView_cancel-bottom"); $expected = array( diff --git a/tests/phpunit/WebTest/Contribute/UpdateBatchPendingContributionTest.php b/tests/phpunit/WebTest/Contribute/UpdateBatchPendingContributionTest.php index 1448792be7..75b2640f29 100644 --- a/tests/phpunit/WebTest/Contribute/UpdateBatchPendingContributionTest.php +++ b/tests/phpunit/WebTest/Contribute/UpdateBatchPendingContributionTest.php @@ -48,10 +48,11 @@ class WebTest_Contribute_UpdateBatchPendingContributionTest extends CiviSelenium $this->clickLink("_qf_Search_refresh"); $this->click('radio_ts', 'ts_all'); - + $this->waitForAjaxContent(); $this->select('task', "label=Update pending contribution status"); - $this->click("_qf_Search_next_action"); + $this->waitForAjaxContent(); $this->select('contribution_status_id', 'label=Completed'); + $this->waitForAjaxContent(); $this->click('_qf_Status_next'); $this->waitForElementPresent("_qf_Result_done"); $this->click("_qf_Result_done"); diff --git a/tests/phpunit/WebTest/Event/AddPricesetTest.php b/tests/phpunit/WebTest/Event/AddPricesetTest.php index dadf06bb2f..9532edaade 100644 --- a/tests/phpunit/WebTest/Event/AddPricesetTest.php +++ b/tests/phpunit/WebTest/Event/AddPricesetTest.php @@ -178,7 +178,7 @@ class WebTest_Event_AddPricesetTest extends CiviSeleniumTestCase { default: break; } - $this->clickLink('_qf_Field_next_new-bottom', '_qf_Field_next-bottom'); + $this->clickLink('_qf_Field_next_new-bottom', '_qf_Field_next-bottom', FALSE); $this->waitForText('crm-notification-container', "Price Field '" . $label . "' has been saved."); } } @@ -193,7 +193,7 @@ class WebTest_Event_AddPricesetTest extends CiviSeleniumTestCase { $this->openCiviPage('admin/price', 'reset=1'); // Use the price set id ($sid) to pick the correct row - $this->clickLink("//*[@id='price_set-{$sid}']/td[4]/span[1]/a[2]", '_qf_Preview_cancel-bottom'); + $this->clickLink("//*[@id='price_set-{$sid}']/td[4]/span[1]/a[2]", '_qf_Preview_cancel-bottom', FALSE); // Check for expected price set field strings if ($this->isElementPresent("xpath=//*[@class ='select2-chosen']")) { diff --git a/tests/phpunit/WebTest/Event/ParticipantCountTest.php b/tests/phpunit/WebTest/Event/ParticipantCountTest.php index 0072a69cf4..036c947959 100644 --- a/tests/phpunit/WebTest/Event/ParticipantCountTest.php +++ b/tests/phpunit/WebTest/Event/ParticipantCountTest.php @@ -433,7 +433,7 @@ class WebTest_Event_ParticipantCountTest extends CiviSeleniumTestCase { $this->select('billing_state_province_id-5', 'value=1004'); $this->type('billing_postal_code-5', '94129'); - $this->clickLink('_qf_Register_upload-bottom', '_qf_Confirm_next-bottom'); + $this->clickLink('_qf_Register_upload-bottom', '_qf_Confirm_next-bottom', FALSE); $confirmStrings = array('Event Fee(s)', 'Billing Name and Address', 'Credit Card Information'); $this->assertStringsPresent($confirmStrings); $this->click('_qf_Confirm_next-bottom'); -- 2.25.1