function ViewExecutableTest::testDestroy in Views (for Drupal 7) 8.3
Tests the deconstructor to be sure that every kind of heavy objects are removed.
File
- lib/
Drupal/ views/ Tests/ ViewExecutableTest.php, line 158 - Definition of Drupal\views\Tests\ViewExecutableTest.
Class
- ViewExecutableTest
- Tests the ViewExecutable class.
Namespace
Drupal\views\TestsCode
function testDestroy() {
$view = $this
->getView();
$view
->preview();
$view
->destroy();
$this
->assertViewDestroy($view);
// Manipulate the display variable to test a previous bug.
$view = $this
->getView();
$view
->preview();
$view
->destroy();
$this
->assertViewDestroy($view);
}