| Total Complexity | 2 |
| Total Lines | 23 |
| Duplicated Lines | 0 % |
| Changes | 4 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 13 | final class GacelaTest extends TestCase |
||
| 14 | { |
||
| 15 | public function test_exception_if_non_bootstrapped(): void |
||
| 16 | { |
||
| 17 | // Needed in order to set up the private `Gacela::$appRootDir as null` for this use case |
||
| 18 | // when you try to access it before bootstrapping the application. |
||
| 19 | $gacelaProxy = new ReflectionClass(Gacela::class); |
||
| 20 | $appRootDirProp = $gacelaProxy->getProperty('appRootDir'); |
||
| 21 | $appRootDirProp->setAccessible(true); |
||
| 22 | $appRootDirProp->setValue(null); |
||
| 23 | |||
| 24 | $this->expectException(GacelaNotBootstrappedException::class); |
||
| 25 | |||
| 26 | Gacela::rootDir(); |
||
| 27 | } |
||
| 28 | |||
| 29 | public function test_get_cache_dir(): void |
||
| 36 | } |
||
| 37 | } |
||
| 38 |