You are here

protected function FileEntityPathsHelper::setFileNamePatterns in File Entity Paths 7.2

Create 10 random filename with random extension. + Add the original pattern.

File

tests/fe_paths.test, line 64
Tests for File Entity Paths

Class

FileEntityPathsHelper
@file Tests for File Entity Paths

Code

protected function setFileNamePatterns() {
  while (!isset($this->fileNamePatterns[9])) {
    $this->fileNamePatterns[] = $this
      ->randomName(8) . '.' . $this
      ->randomName(3);
  }
  $this->fileNamePatterns['original'] = '[file:name-only-original].[file:extension-original]';
}