function MigrateContactSettingsTest::testContactSettings

Same name in this branch
  1. 9 core/modules/contact/tests/src/Kernel/Migrate/d7/MigrateContactSettingsTest.php \Drupal\Tests\contact\Kernel\Migrate\d7\MigrateContactSettingsTest::testContactSettings()
Same name in other branches
  1. 8.9.x core/modules/contact/tests/src/Kernel/Migrate/d6/MigrateContactSettingsTest.php \Drupal\Tests\contact\Kernel\Migrate\d6\MigrateContactSettingsTest::testContactSettings()
  2. 8.9.x core/modules/contact/tests/src/Kernel/Migrate/d7/MigrateContactSettingsTest.php \Drupal\Tests\contact\Kernel\Migrate\d7\MigrateContactSettingsTest::testContactSettings()
  3. 10 core/modules/contact/tests/src/Kernel/Migrate/d6/MigrateContactSettingsTest.php \Drupal\Tests\contact\Kernel\Migrate\d6\MigrateContactSettingsTest::testContactSettings()
  4. 10 core/modules/contact/tests/src/Kernel/Migrate/d7/MigrateContactSettingsTest.php \Drupal\Tests\contact\Kernel\Migrate\d7\MigrateContactSettingsTest::testContactSettings()
  5. 11.x core/modules/contact/tests/src/Kernel/Migrate/d6/MigrateContactSettingsTest.php \Drupal\Tests\contact\Kernel\Migrate\d6\MigrateContactSettingsTest::testContactSettings()
  6. 11.x core/modules/contact/tests/src/Kernel/Migrate/d7/MigrateContactSettingsTest.php \Drupal\Tests\contact\Kernel\Migrate\d7\MigrateContactSettingsTest::testContactSettings()

Tests migration of contact variables to contact.settings.yml.

File

core/modules/contact/tests/src/Kernel/Migrate/d6/MigrateContactSettingsTest.php, line 33

Class

MigrateContactSettingsTest
Upgrade variables to contact.settings.yml.

Namespace

Drupal\Tests\contact\Kernel\Migrate\d6

Code

public function testContactSettings() {
    $config = $this->config('contact.settings');
    $this->assertTrue($config->get('user_default_enabled'));
    $this->assertSame(3, $config->get('flood.limit'));
    $this->assertSame('some_other_category', $config->get('default_form'));
    $this->assertConfigSchema(\Drupal::service('config.typed'), 'contact.settings', $config->get());
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.