public function CronRunTest::testManualCron in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/modules/system/src/Tests/System/CronRunTest.php \Drupal\system\Tests\System\CronRunTest::testManualCron()
Ensure that the manual cron run is working.
File
- core/
modules/ system/ src/ Tests/ System/ CronRunTest.php, line 117 - Contains \Drupal\system\Tests\System\CronRunTest.
Class
- CronRunTest
- Tests cron runs.
Namespace
Drupal\system\Tests\SystemCode
public function testManualCron() {
$admin_user = $this
->drupalCreateUser(array(
'administer site configuration',
));
$this
->drupalLogin($admin_user);
$this
->drupalGet('admin/reports/status/run-cron');
$this
->assertResponse(403);
$this
->drupalGet('admin/reports/status');
$this
->clickLink(t('run cron manually'));
$this
->assertResponse(200);
$this
->assertText(t('Cron ran successfully.'));
}