WebTestFix
authorAtif Shaikh <shaikh388@gmail.com>
Tue, 6 May 2014 14:17:42 +0000 (19:47 +0530)
committerAtif Shaikh <shaikh388@gmail.com>
Tue, 6 May 2014 14:17:42 +0000 (19:47 +0530)
tests/phpunit/CiviTest/CiviSeleniumTestCase.php
tests/phpunit/WebTest/Contribute/ContributionPageAddTest.php

index 890153e1ee45cba93eaf45f17e148f13d7124c77..289cd936fa93f76e6fe22e16e029f37f20da7b3a 100644 (file)
@@ -849,7 +849,7 @@ class CiviSeleniumTestCase extends PHPUnit_Extensions_SeleniumTestCase {
 
     if ($onBehalf) {
       $this->click('is_organization');
-      $this->select('onbehalf_profile_id', 'label=On Behalf Of Organization');
+      $this->select("xpath=//*[@class='crm-contribution-onbehalf_profile_id']//span[@class='crm-profile-selector-select']//select", 'label=On Behalf Of Organization');
       $this->type('for_organization', "On behalf $hash");
 
       if ($onBehalf == 'required') {
index b88561758d25d9755350e47d938c91690e888208..aea39215bb1a64f2b230e627fb70bf476827c902 100644 (file)
@@ -59,9 +59,6 @@ class WebTest_Contribute_ContributionPageAddTest extends CiviSeleniumTestCase {
       'Organization Details',
       'Other Amount',
       'I pledge to contribute this amount every',
-      "Honoree Section Title $hash",
-      "Honoree Introductory Message $hash",
-      'In Honor of',
       'Name and Address',
       'Summary Overlay',
     );
@@ -69,7 +66,7 @@ class WebTest_Contribute_ContributionPageAddTest extends CiviSeleniumTestCase {
       $this->assertTrue($this->isTextPresent($text), 'Missing text: ' . $text);
     }
   }
-
+  
   // CRM-12510 Test copy contribution page
   function testContributionPageCopy() {
     // open browser, login
@@ -117,9 +114,6 @@ class WebTest_Contribute_ContributionPageAddTest extends CiviSeleniumTestCase {
       'Organization Details',
       'Other Amount',
       'I pledge to contribute this amount every',
-      "Honoree Section Title $hash",
-      "Honoree Introductory Message $hash",
-      'In Honor of',
       'Name and Address',
       'Summary Overlay',
     );
@@ -165,9 +159,6 @@ class WebTest_Contribute_ContributionPageAddTest extends CiviSeleniumTestCase {
       'Organization Details',
       'Other Amount',
       'I pledge to contribute this amount every',
-      "Honoree Section Title $hash",
-      "Honoree Introductory Message $hash",
-      'In Honor of',
       'Name and Address',
       'Summary Overlay',
     );
@@ -301,7 +292,7 @@ class WebTest_Contribute_ContributionPageAddTest extends CiviSeleniumTestCase {
     $this->select('financial_type_id', "label=Donation");
 
     $this->click('is_organization');
-    $this->select('onbehalf_profile_id', 'label=On Behalf Of Organization');
+    $this->select("xpath=//*[@class='crm-contribution-onbehalf_profile_id']//span[@class='crm-profile-selector-select']//select", 'label=On Behalf Of Organization');
     $this->type('for_organization', "On behalf $hash");
     // make onBehalf optional
     $this->click('CIVICRM_QFID_1_2');