X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=tests%2Fphpunit%2FWebTest%2FContact%2FGroupAddTest.php;h=3eb09cb810f06e71165913518ca439dbbd40e586;hb=c24be2289c776d9ee74980d0db74996804bd0eff;hp=98ead2ad6eb32f19b87088103642cc13100dfbf0;hpb=95ca1e4e775ce88e3f371abe8390a3526ba537e7;p=civicrm-core.git diff --git a/tests/phpunit/WebTest/Contact/GroupAddTest.php b/tests/phpunit/WebTest/Contact/GroupAddTest.php index 98ead2ad6e..3eb09cb810 100644 --- a/tests/phpunit/WebTest/Contact/GroupAddTest.php +++ b/tests/phpunit/WebTest/Contact/GroupAddTest.php @@ -1,7 +1,7 @@ webtestLogin(); $this->openCiviPage('group/add', 'reset=1', '_qf_Edit_upload-bottom'); @@ -104,7 +104,7 @@ class WebTest_Contact_GroupAddTest extends CiviSeleniumTestCase { $this->assertElementContainsText("css=div.crm-summary-display_name", $displayName); } - function testGroupReserved() { + public function testGroupReserved() { $this->webtestLogin('admin'); $this->openCiviPage('group/add', 'reset=1', '_qf_Edit_upload-bottom'); @@ -186,7 +186,7 @@ class WebTest_Contact_GroupAddTest extends CiviSeleniumTestCase { * * @return string */ - function _testCreateUser($roleid) { + public function _testCreateUser($roleid) { $this->open($this->sboxPath . "admin/people/create"); $this->waitForElementPresent("edit-submit"); @@ -222,7 +222,7 @@ class WebTest_Contact_GroupAddTest extends CiviSeleniumTestCase { /** * @param $role */ - function _roleDelete($role) { + public function _roleDelete($role) { $this->waitForElementPresent("xpath=//table[@id='user-roles']/tbody//tr/td[text()='{$role}']/..//td/a[text()='edit role']"); $this->click("xpath=//table[@id='user-roles']/tbody//tr/td[text()='{$role}']/..//td/a[text()='edit role']"); $this->waitForElementPresent('edit-delete'); @@ -232,17 +232,17 @@ class WebTest_Contact_GroupAddTest extends CiviSeleniumTestCase { $this->waitForTextPresent("The role has been deleted."); } - /** - * Webtest for add contact to group (CRM-15108) - */ - function testAddContactToGroup() { + /** + * Webtest for add contact to group (CRM-15108) + */ + public function testAddContactToGroup() { $this->webtestLogin(); $this->openCiviPage("contact/add", "reset=1&ct=Individual"); $this->waitForElementPresent('_qf_Contact_upload_view-bottom'); //Create contact. $group = "Advisory Board"; - $firstName = "Adams".substr(sha1(rand()), 0, 4); + $firstName = "Adams" . substr(sha1(rand()), 0, 4); $lastName = substr(sha1(rand()), 0, 4); $email = "{$lastName}.{$firstName}@example.org"; $this->type('first_name', $firstName); @@ -273,7 +273,7 @@ class WebTest_Contact_GroupAddTest extends CiviSeleniumTestCase { $this->openCiviPage('contact/search', 'reset=1'); $this->waitForElementPresent("_qf_Basic_refresh"); $this->type('sort_name', $firstName); - $this->select('group',"Advisory Board"); + $this->select('group', "Advisory Board"); $this->click('_qf_Basic_refresh'); $this->waitForPageToLoad($this->getTimeoutMsec()); $this->assertTrue($this->isElementPresent("xpath=//table/tbody//tr/td[3]/a[text()='{$lastName}, {$firstName}']"));