Skip to content
Snippets Groups Projects
Commit 4ef1780a authored by Kurund Jalmi's avatar Kurund Jalmi
Browse files

Merge pull request #271 from ravishnair/webtest-fix/improvement

-- webtest fixes and improvement
parents f5eef6ad baaf85ee
Branches
Tags
No related merge requests found
......@@ -534,8 +534,8 @@ class WebTest_Campaign_SurveyUsageScenarioTest extends CiviSeleniumTestCase {
$this->waitForElementPresent('_qf_Interview_cancel_interview');
$this->type("field_{$id1}_phone-Primary-1", 9876543210);
$this->click("//table[@id='voterRecords']/tbody//tr[@id='row_{$id1}']/td[5]/input[2]/../label[text()='$label1']");
$this->click("//table[@id='voterRecords']/tbody//tr[@id='row_{$id1}']/td[5]/input[6]/../label[text()='$label2']");
$this->click("//table[@id='voterRecords']/tbody//tr[@id='row_{$id1}']/td[7]/input[2]/../label[text()='$label1']");
$this->click("//table[@id='voterRecords']/tbody//tr[@id='row_{$id1}']/td[7]/input[6]/../label[text()='$label2']");
$this->select("field_{$id1}_result", $optionLabel1);
$this->click("interview_voter_button_{$id1}");
// Because it tends to cause problems, all uses of sleep() must be justified in comments
......
......@@ -206,7 +206,7 @@ class WebTest_Case_ActivityToCaseTest extends CiviSeleniumTestCase {
$this->click("xpath=//div[@id='activities']//table[@id='activities-selector']/tbody//tr/td[2]/a[text()='{$subject}']/../../td[6]/a[text()='Scheduled']");
$this->waitForElementPresent("css=div#changeStatusDialog");
$this->waitForElementPresent("xpath=//html/body/div[7]");
$this->waitForElementPresent('activity_change_status');
// change activity status
......
......@@ -101,7 +101,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase {
$this->click("_qf_Contact_refresh_dedupe");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->assertTrue($this->isTextPresent("One matching contact was found. You can View or Edit the existing contact."));
$this->waitForText('crm-notification-container', "One matching contact was found. You can View or Edit the existing contact.");
$this->click("_qf_Contact_upload_duplicate");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->waitForText('crm-notification-container', "Contact Saved");
......@@ -119,7 +119,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase {
$this->type("email_1_email", $email2);
$this->click("_qf_Contact_refresh_dedupe");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->assertTrue($this->isTextPresent("One matching contact was found. You can View or Edit the existing contact."));
$this->waitForText('crm-notification-container', "One matching contact was found. You can View or Edit the existing contact.");
$this->click("_qf_Contact_upload_duplicate");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->waitForText('crm-notification-container', "Contact Saved");
......@@ -263,7 +263,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase {
$this->waitForPageToLoad($this->getTimeoutMsec());
// Is status message correct?
$this->assertTrue($this->isTextPresent("Activity '$subject' has been saved."), "Status message didn't show up after saving!");
$this->waitForText('crm-notification-container', "Activity '$subject' has been saved.", "Status message didn't show up after saving!");
}
function testMergeTest() {
......@@ -322,7 +322,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase {
$this->click("_qf_Contact_refresh_dedupe");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->assertTrue($this->isTextPresent("One matching contact was found. You can View or Edit the existing contact."));
$this->waitForText('crm-notification-container', "One matching contact was found. You can View or Edit the existing contact.");
$this->click("_qf_Contact_upload_duplicate");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->waitForText('crm-notification-container', "Contact Saved");
......@@ -411,7 +411,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase {
// Clicking save.
$this->click("_qf_Contact_refresh_dedupe");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->assertTrue($this->isTextPresent("One matching contact was found. You can View or Edit the existing contact."));
$this->waitForText('crm-notification-container', "One matching contact was found. You can View or Edit the existing contact.");
$this->click("_qf_Contact_upload_duplicate");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->waitForText('crm-notification-container', "Contact Saved");
......@@ -520,7 +520,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase {
$this->click("_qf_Contact_refresh_dedupe");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->assertTrue($this->isTextPresent("One matching contact was found. You can View or Edit the existing contact."));
$this->waitForText('crm-notification-container', "One matching contact was found. You can View or Edit the existing contact.");
$this->click("_qf_Contact_upload_duplicate");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->waitForText('crm-notification-container', "Contact Saved");
......@@ -629,7 +629,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase {
$this->click("_qf_Contact_refresh_dedupe");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->assertTrue($this->isTextPresent("One matching contact was found. You can View or Edit the existing contact."));
$this->waitForText('crm-notification-container', "One matching contact was found. You can View or Edit the existing contact.");
$this->click("_qf_Contact_upload_duplicate");
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->waitForText('crm-notification-container', "Contact Saved");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment