function InstallTranslationFilePatternTest::testFilesPatternInvalid

Same name in other branches
  1. 9 core/modules/system/tests/src/Kernel/Installer/InstallTranslationFilePatternTest.php \Drupal\Tests\system\Kernel\Installer\InstallTranslationFilePatternTest::testFilesPatternInvalid()
  2. 8.9.x core/modules/system/tests/src/Kernel/Installer/InstallTranslationFilePatternTest.php \Drupal\Tests\system\Kernel\Installer\InstallTranslationFilePatternTest::testFilesPatternInvalid()
  3. 10 core/modules/system/tests/src/Kernel/Installer/InstallTranslationFilePatternTest.php \Drupal\Tests\system\Kernel\Installer\InstallTranslationFilePatternTest::testFilesPatternInvalid()

@dataProvider providerInvalidTranslationFiles

File

core/modules/system/tests/src/Kernel/Installer/InstallTranslationFilePatternTest.php, line 64

Class

InstallTranslationFilePatternTest
Tests for installer language support.

Namespace

Drupal\Tests\system\Kernel\Installer

Code

public function testFilesPatternInvalid($langcode, $filename) : void {
    $pattern = $this->filePatternMethod
        ->invoke($this->fileTranslation, $langcode);
    $this->assertEmpty(preg_match($pattern, $filename));
}

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