X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=tests%2Fphpunit%2FWebTest%2FImport%2FParticipantTest.php;h=3c722aaa0b8507a06e1a030b97ed2b1289a15af4;hb=b78a8038cd5f8631030ae902e194f5958f3b34f2;hp=a3d144fa5b426400736d872fa25187e1209c5cfd;hpb=149e631532beb9953cde6af3e647bbc82ee2e3d5;p=civicrm-core.git diff --git a/tests/phpunit/WebTest/Import/ParticipantTest.php b/tests/phpunit/WebTest/Import/ParticipantTest.php index a3d144fa5b..3c722aaa0b 100644 --- a/tests/phpunit/WebTest/Import/ParticipantTest.php +++ b/tests/phpunit/WebTest/Import/ParticipantTest.php @@ -1,9 +1,9 @@ open($this->sboxPath); - // Log in using webtestLogin() method $this->webtestLogin(); // Get sample import data. list($headers, $rows) = $this->_participantIndividualCSVData(); - + // Create and import csv from provided data and check imported data. $fieldMapper = array( 'mapper[0][0]' => 'email', @@ -62,11 +56,6 @@ class WebTest_Import_ParticipantTest extends ImportCiviSeleniumTestCase { * Test participant import for Organizations. */ function testParticipantImportOrganization() { - // This is the path where our testing install resides. - // The rest of URL is defined in CiviSeleniumTestCase base class, in - // class attributes. - $this->open($this->sboxPath); - // Log in using webtestLogin() method $this->webtestLogin(); @@ -88,11 +77,6 @@ class WebTest_Import_ParticipantTest extends ImportCiviSeleniumTestCase { * Test participant import for Households. */ function testParticipantImportHousehold() { - // This is the path where our testing install resides. - // The rest of URL is defined in CiviSeleniumTestCase base class, in - // class attributes. - $this->open($this->sboxPath); - // Log in using webtestLogin() method $this->webtestLogin(); @@ -273,7 +257,6 @@ class WebTest_Import_ParticipantTest extends ImportCiviSeleniumTestCase { $this->openCiviPage('event/add', 'reset=1&action=add', '_qf_EventInfo_upload-bottom'); - // Let's start filling the form with values. $this->select("event_type_id", "value={$params['event_type_id']}"); // Attendee role s/b selected now. @@ -338,13 +321,9 @@ class WebTest_Import_ParticipantTest extends ImportCiviSeleniumTestCase { // verify event input on info page // start at Manage Events listing $this->openCiviPage('event/manage', 'reset=1'); - $this->click("link=" . $params['title']); - - $this->waitForPageToLoad($this->getTimeoutMsec()); + $this->clickLink("link=" . $params['title'], NULL); - $matches = array(); - preg_match('/id=([0-9]+)/', $this->getLocation(), $matches); - $params['event_id'] = $matches[1]; + $params['event_id'] = $this->urlArg('id');; return $params; }