You are here

public function ConfigIgnoreSettingsTest::testSettingsForm in Config Ignore 8

Verify that the settings form works.

File

src/Tests/ConfigIgnoreSettingsTest.php, line 25

Class

ConfigIgnoreSettingsTest
Class ConfigIgnoreSettingsTest.

Namespace

Drupal\config_ignore\Tests

Code

public function testSettingsForm() {

  // Login with a user that has permission to import config.
  $this
    ->drupalLogin($this
    ->drupalCreateUser([
    'import configuration',
  ]));
  $edit = [
    'ignored_config_entities' => 'config.test',
  ];
  $this
    ->drupalPostForm('admin/config/development/configuration/ignore', $edit, t('Save configuration'));
  $settings = $this
    ->config('config_ignore.settings')
    ->get('ignored_config_entities');
  $this
    ->assertEqual($settings, [
    'config.test',
  ]);
}