ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilServicesFileSystemTest.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
24use PHPUnit\Framework\TestCase;
25use ilFileData;
26
27class ilServicesFileSystemTest extends TestCase
28{
29 private ?Container $dic_backup = null;
30
31 public function testTrailingSlashes(): void
32 {
33 $file_data = new ilFileData();
34 $this->assertSame('/var/www/ilias', $file_data->deleteTrailingSlash('/var/www/ilias/'));
35 $this->assertSame('\\var\\www\\ilias', $file_data->deleteTrailingSlash('\\var\\www\\ilias\\'));
36 }
37
38 public function testBaseDirectory(): void
39 {
40 if (!defined('CLIENT_DATA_DIR')) {
41 define('CLIENT_DATA_DIR', '/var/iliasdata');
42 }
43 $file_data = new ilFileData();
44 $this->assertEquals(CLIENT_DATA_DIR, $file_data->getPath());
45 }
46}
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:36
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
const CLIENT_DATA_DIR
Definition: constants.php:46