You are here

protected function TestviewConfiguration::createConfigToExport in Configuration Management 7.2

This function creates the configurations that will be exported by configuration management.

Overrides ConfigurationHandlerBaseTestCase::createConfigToExport

File

tests/handlers/TestViewConfiguration.test, line 86
Tests for Configuration Management: Views.

Class

TestviewConfiguration
@file Tests for Configuration Management: Views.

Code

protected function createConfigToExport() {
  $web_user = $this
    ->drupalCreateUser(array(
    'administer views',
    'access content',
  ));
  $this
    ->drupalLogin($web_user);
  $edit = array();
  $edit['human_name'] = 'Test';
  $edit['name'] = $this->view_name = strtolower($this
    ->randomName(10));
  $edit['page[title]'] = 'My custom view';
  $edit['page[path]'] = 'custom_view';
  $this
    ->drupalPost('admin/structure/views/add', $edit, t('Save & exit'));
}