public function SearchByPageTester::doCronRun in Search by Page 6
Same name and namespace in other branches
- 7 tests/search_by_page.test \SearchByPageTester::doCronRun()
Updates the search index.
Logs current user out, and runs cron to make sure search content is indexed.
File
- tests/
search_by_page.test, line 178 - Tests for the Search by Page module. By Jennifer Hodgdon of Poplar ProductivityWare, www.poplarware.com
Class
- SearchByPageTester
- Base class for testing Search by Page.
Code
public function doCronRun() {
// Make sure we are logged out before cron run.
if ($this->loggedInUser) {
$this
->drupalLogout();
}
// Note: Could use $this->cronRun(), but not available in 6.x SimpleTest,
// so using the body of cronRun() from Drupal 7 instead
$this
->drupalGet($GLOBALS['base_url'] . '/cron.php', array(
'external' => TRUE,
'query' => array(
'cron_key' => variable_get('cron_key', 'drupal'),
),
));
}