1 views_access.test | ViewsAccessTest::view_access_perm() |
File
- core/
modules/ views/ tests/ views_access.test, line 203 - Definition of ViewsAccessTest.
Class
- ViewsAccessTest
- Basic test for pluggable access.
Code
function view_access_perm() {
$view = new view;
$view->name = 'test_access_perm';
$view->description = '';
$view->tag = '';
$view->view_php = '';
$view->base_table = 'node';
$view->is_cacheable = FALSE;
$view->api_version = 2;
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
/* Display: Default */
$handler = $view->new_display('default', 'Default', 'default');
$handler->display->display_options['access']['type'] = 'perm';
$handler->display->display_options['access']['perm'] = 'views_test test permission';
$handler->display->display_options['cache']['type'] = 'none';
$handler->display->display_options['exposed_form']['type'] = 'basic';
$handler->display->display_options['pager']['type'] = 'full';
$handler->display->display_options['style_plugin'] = 'default';
$handler->display->display_options['row_plugin'] = 'fields';
return $view;
}