ILIAS  release_10 Revision v10.1-43-ga1241a92c2f
ILIAS\App\tests\RootFolderTest Class Reference

Class RootFolderTest. More...

+ Inheritance diagram for ILIAS\App\tests\RootFolderTest:
+ Collaboration diagram for ILIAS\App\tests\RootFolderTest:

Protected Member Functions

 setUp ()
 

Protected Attributes

array $ALLOWED_ROOT_FOLDER_DIRS = []
 
array $ALLOWED_ROOT_FOLDER_FILES = []
 

Private Member Functions

 getAppRootFolderOrFail ()
 

Private Attributes

const ALLOWED_ROOT_FOLDER_FILES
 
const ALLOWED_ROOT_FOLDER_DIRS
 

Detailed Description

Class RootFolderTest.

Author
Michael Jansen mjans.nosp@m.en@d.nosp@m.ataba.nosp@m.y.de

Definition at line 29 of file RootFolderTest.php.

Member Function Documentation

◆ getAppRootFolderOrFail()

ILIAS\App\tests\RootFolderTest::getAppRootFolderOrFail ( )
private

Definition at line 90 of file RootFolderTest.php.

References ILIAS\App\tests\RootFolderTest\ALLOWED_ROOT_FOLDER_DIRS, ILIAS\App\tests\RootFolderTest\ALLOWED_ROOT_FOLDER_FILES, and ILIAS\UI\examples\Symbol\Glyph\Sort\sort().

90  : string
91  {
92  $app_root_folder = __DIR__ . "/../../../../";
93 
94  if (!is_file($app_root_folder . '/ilias_version.php')) {
95  $this->fail('Could not determine ILIAS root folder');
96  }
97 
98  return $app_root_folder;
99  }
+ Here is the call graph for this function:

◆ setUp()

ILIAS\App\tests\RootFolderTest::setUp ( )
protected

Definition at line 78 of file RootFolderTest.php.

References ILIAS\App\tests\RootFolderTest\ALLOWED_ROOT_FOLDER_DIRS, and ILIAS\App\tests\RootFolderTest\ALLOWED_ROOT_FOLDER_FILES.

78  : void
79  {
80  $this->ALLOWED_ROOT_FOLDER_DIRS = array_merge(
81  self::ALLOWED_ROOT_FOLDER_DIRS,
82  explode(",", (string) getenv('ALLOWED_ROOT_FOLDER_DIRS'))
83  );
84  $this->ALLOWED_ROOT_FOLDER_FILES = array_merge(
85  self::ALLOWED_ROOT_FOLDER_FILES,
86  explode(",", (string) getenv('ALLOWED_ROOT_FOLDER_FILES'))
87  );
88  }

Field Documentation

◆ $ALLOWED_ROOT_FOLDER_DIRS

array ILIAS\App\tests\RootFolderTest::$ALLOWED_ROOT_FOLDER_DIRS = []
protected

Definition at line 75 of file RootFolderTest.php.

◆ $ALLOWED_ROOT_FOLDER_FILES

array ILIAS\App\tests\RootFolderTest::$ALLOWED_ROOT_FOLDER_FILES = []
protected

Definition at line 76 of file RootFolderTest.php.

◆ ALLOWED_ROOT_FOLDER_DIRS

const ILIAS\App\tests\RootFolderTest::ALLOWED_ROOT_FOLDER_DIRS
private
Initial value:
= [
'.git',
'.github',
'.idea',
'artifacts',
'cli',
'components',
'docs',
'extern',
'lang',
'node_modules',
'public',
'scripts',
'templates',
'vendor',
'.settings'
]

Definition at line 57 of file RootFolderTest.php.

Referenced by ILIAS\App\tests\RootFolderTest\getAppRootFolderOrFail(), and ILIAS\App\tests\RootFolderTest\setUp().

◆ ALLOWED_ROOT_FOLDER_FILES

const ILIAS\App\tests\RootFolderTest::ALLOWED_ROOT_FOLDER_FILES
private
Initial value:
= [
'.eslintrc.json',
'.gitignore',
'.htaccess',
'.phpunit.result.cache',
'captainhook.local.json',
'phpstan.local.neon',
'phpstan-baseline.neon',
'.php_cs.cache',
'.php-cs-fixer.cache',
'captainhook.json',
'composer.json',
'composer_new.json',
'composer.lock',
'ilias.ini.php',
'ilias_version.php',
'LICENSE',
'package-lock.json',
'package.json',
'README.md',
'unzip_test_file.zip',
'.DS_Store',
'.buildpath',
'.project'
]

Definition at line 31 of file RootFolderTest.php.

Referenced by ILIAS\App\tests\RootFolderTest\getAppRootFolderOrFail(), and ILIAS\App\tests\RootFolderTest\setUp().


The documentation for this class was generated from the following file: