function ShutdownFunctionsTest::testShutdownFunctions
Same name in other branches
- 9 core/modules/system/tests/src/Functional/System/ShutdownFunctionsTest.php \Drupal\Tests\system\Functional\System\ShutdownFunctionsTest::testShutdownFunctions()
- 8.9.x core/modules/system/tests/src/Functional/System/ShutdownFunctionsTest.php \Drupal\Tests\system\Functional\System\ShutdownFunctionsTest::testShutdownFunctions()
- 10 core/modules/system/tests/src/Functional/System/ShutdownFunctionsTest.php \Drupal\Tests\system\Functional\System\ShutdownFunctionsTest::testShutdownFunctions()
- 11.x core/modules/system/tests/src/Functional/System/ShutdownFunctionsTest.php \Drupal\Tests\system\Functional\System\ShutdownFunctionsTest::testShutdownFunctions()
Test shutdown functions.
File
-
modules/
system/ system.test, line 2799
Class
- ShutdownFunctionsTest
- Functional tests shutdown functions.
Code
function testShutdownFunctions() {
$arg1 = $this->randomName();
$arg2 = $this->randomName();
$this->drupalGet('system-test/shutdown-functions/' . $arg1 . '/' . $arg2);
$this->assertText(t('First shutdown function, arg1 : @arg1, arg2: @arg2', array(
'@arg1' => $arg1,
'@arg2' => $arg2,
)));
$this->assertText(t('Second shutdown function, arg1 : @arg1, arg2: @arg2', array(
'@arg1' => $arg1,
'@arg2' => $arg2,
)));
// Make sure exceptions displayed through _drupal_render_exception_safe()
// are correctly escaped.
$this->assertRaw('Drupal is <blink>awesome</blink>.');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.