public function CdnSchemeSettingsUpdateTest::testStreamWrapperSettingsAdded in CDN 8.3
Tests default settings can be detected, and are updated.
It's possible to automatically update the settings as long as the only thing that's modified by the end user is the 'domain' (NULL by default).
File
- tests/
src/ Functional/ Update/ CdnSchemeSettingsUpdateTest.php, line 34
Class
- CdnSchemeSettingsUpdateTest
- Tests that existing sites also get the new "scheme" setting.
Namespace
Drupal\Tests\cdn\Functional\UpdateCode
public function testStreamWrapperSettingsAdded() {
// Make sure we have the expected values before the update.
$cdn_settings = $this
->config('cdn.settings');
$this
->assertNull($cdn_settings
->get('scheme'));
$this
->runUpdates();
// Make sure we have the expected values after the update.
$cdn_settings = $this
->config('cdn.settings');
$this
->assertSame('//', $cdn_settings
->get('scheme'));
}