X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=tests%2Fphpunit%2FWebTest%2FReport%2FLoggingReportTest.php;h=8a28e6130e428815b9402ef5b369bd21f5b01622;hb=481a74f476c945a324382bad34630d1a78d704c7;hp=febed4d7a342bbcbc3da49a1fdc6ba6cb65f8cae;hpb=fa92b4af1c4abf280689cea6445c7a9b99858831;p=civicrm-core.git diff --git a/tests/phpunit/WebTest/Report/LoggingReportTest.php b/tests/phpunit/WebTest/Report/LoggingReportTest.php index febed4d7a3..8a28e6130e 100644 --- a/tests/phpunit/WebTest/Report/LoggingReportTest.php +++ b/tests/phpunit/WebTest/Report/LoggingReportTest.php @@ -150,7 +150,7 @@ class WebTest_Report_LoggingReportTest extends CiviSeleniumTestCase { $this->waitForElementPresent("xpath=//table[@class='contact-activity-selector-activity dataTable no-footer']/tbody/tr/td[8]/span/a[2]"); $this->click("xpath=//table[@class='contact-activity-selector-activity dataTable no-footer']/tbody/tr/td[8]/span/a[2]"); $this->waitForElementPresent("_qf_Activity_cancel-bottom"); - $this->select("status_id","value=2"); + $this->select("status_id", "value=2"); $this->click('_qf_Activity_upload-bottom'); $this->waitForText("crm-notification-container", "Activity has been saved."); $this->waitForElementPresent("xpath=//table[@class='contact-activity-selector-activity dataTable no-footer']/tbody/tr/td[7][text()='Completed']"); @@ -161,15 +161,15 @@ class WebTest_Report_LoggingReportTest extends CiviSeleniumTestCase { $this->waitForElementPresent("xpath=//div[@class='view-content']//div[@class='action-link']/a"); $this->click("xpath=//div[@class='view-content']//div[@class='action-link']/a"); $this->waitForElementPresent("_qf_Case_cancel-bottom"); - $this->type('activity_subject',"subject".rand()); - $this->select('case_type_id','value=1'); + $this->type('activity_subject', "subject".rand()); + $this->select('case_type_id', 'value=1'); $this->click('_qf_Case_upload-bottom'); $this->waitForElementPresent("xpath=//form[@id='Search']/div[2]/div/table/tbody/tr[2]/td[9]/span[1]/a[1][text()='Manage']"); $this->click("xpath=//form[@id='Search']/div[2]/div/table/tbody/tr[2]/td[9]/span[1]/a[1][text()='Manage']"); $this->waitForElementPresent("xpath=//form[@id='CaseView']/div[2]/table/tbody/tr/td[4]/a"); $this->click("xpath=//form[@id='CaseView']/div[2]/table/tbody/tr/td[4]/a"); $this->waitForElementPresent("_qf_Activity_cancel-bottom"); - $this->select("case_status_id","value=2"); + $this->select("case_status_id", "value=2"); $this->click("_qf_Activity_upload-top"); $this->waitForElementPresent("_qf_CaseView_cancel-bottom"); $this->click("_qf_CaseView_cancel-bottom"); @@ -283,7 +283,7 @@ class WebTest_Report_LoggingReportTest extends CiviSeleniumTestCase { $this->assertTrue($this->isElementPresent("xpath=//table/tbody//tr/td[2][contains(text(), '{$value['log_type']}')]/../{$contactCheck}/../{$actionPath}"), "The proper record not present for (log type : {$value['log_type']}, altered contact : {$value['altered_contact']}, action as {$value['action']})"); if ($value['action'] == 'Update') { - $this->assertTrue( ($value['action'] == $this->getText("xpath=//table/tbody//tr/td[2][contains(text(), '{$value['log_type']}')]/../td[4]/a[contains(text(), '{$value['altered_contact']}')]/../../{$actionPath}")), "The proper record action {$value['action']} not present for (log type : {$value['log_type']}, altered contact : {$value['altered_contact']} record)"); + $this->assertTrue(($value['action'] == $this->getText("xpath=//table/tbody//tr/td[2][contains(text(), '{$value['log_type']}')]/../td[4]/a[contains(text(), '{$value['altered_contact']}')]/../../{$actionPath}")), "The proper record action {$value['action']} not present for (log type : {$value['log_type']}, altered contact : {$value['altered_contact']} record)"); } } } @@ -310,17 +310,17 @@ class WebTest_Report_LoggingReportTest extends CiviSeleniumTestCase { } } - //visit the logging contact summary report - $this->openCiviPage('report/logging/contact/summary', 'reset=1'); - foreach ($filters as $type => $filter) { - if ($type == 'text' ) { - foreach ($filter as $filterName => $filterValue) { - $this->type($filterName, $filterValue); + //visit the logging contact summary report + $this->openCiviPage('report/logging/contact/summary', 'reset=1'); + foreach ($filters as $type => $filter) { + if ($type == 'text') { + foreach ($filter as $filterName => $filterValue) { + $this->type($filterName, $filterValue); + } } } - } - $this->click("_qf_LoggingSummary_submit"); - $this->waitForPageToLoad($this->getTimeoutMsec()); + $this->click("_qf_LoggingSummary_submit"); + $this->waitForPageToLoad($this->getTimeoutMsec()); } } }