public function testDisableLevels()
{
$this->specify("Disabling view levels doesn't work as expected", function () {
$view = $this->_getViewDisabled();
expect($view->getContent())->equals('<html><div class="after-layout"><div class="controller-layout"><div class="before-layout"><div class="action">Action</div></div></div></div></html>' . PHP_EOL);
$view = $this->_getViewDisabled(View::LEVEL_ACTION_VIEW);
expect($view->getContent())->equals('<html><div class="after-layout"><div class="controller-layout"><div class="before-layout"></div></div></div></html>' . PHP_EOL);
$view = $this->_getViewDisabled(View::LEVEL_BEFORE_TEMPLATE);
expect($view->getContent())->equals('<html><div class="after-layout"><div class="controller-layout"><div class="action">Action</div></div></div></html>' . PHP_EOL);
$view = $this->_getViewDisabled(View::LEVEL_LAYOUT);
expect($view->getContent())->equals('<html><div class="after-layout"><div class="before-layout"><div class="action">Action</div></div></div></html>' . PHP_EOL);
$view = $this->_getViewDisabled(View::LEVEL_AFTER_TEMPLATE);
expect($view->getContent())->equals('<html><div class="controller-layout"><div class="before-layout"><div class="action">Action</div></div></div></html>' . PHP_EOL);
$view = $this->_getViewDisabled(View::LEVEL_MAIN_LAYOUT);
expect($view->getContent())->equals('<div class="after-layout"><div class="controller-layout"><div class="before-layout"><div class="action">Action</div></div></div></div>');
$view = $this->_getViewDisabled([View::LEVEL_BEFORE_TEMPLATE => true, View::LEVEL_LAYOUT => true, View::LEVEL_AFTER_TEMPLATE => true, View::LEVEL_MAIN_LAYOUT => true]);
expect($view->getContent())->equals('<div class="action">Action</div>');
});
}