| Total Complexity | 5 |
| Total Lines | 33 |
| Duplicated Lines | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 12 | final class ConfigTest extends TestCase |
||
| 13 | { |
||
| 14 | public function setUp(): void |
||
| 15 | { |
||
| 16 | Gacela::bootstrap(__DIR__, static function (GacelaConfig $config): void { |
||
| 17 | $config->setCacheEnabled(false); |
||
| 18 | }); |
||
| 19 | } |
||
| 20 | |||
| 21 | public function test_get_undefined_key(): void |
||
| 22 | { |
||
| 23 | $this->expectExceptionMessageMatches('/Could not find config key "undefined-key"/'); |
||
| 24 | Config::getInstance()->get('undefined-key'); |
||
| 25 | } |
||
| 26 | |||
| 27 | public function test_get_default_value_from_undefined_key(): void |
||
| 30 | } |
||
| 31 | |||
| 32 | public function test_null_as_default_value_from_undefined_key(): void |
||
| 35 | } |
||
| 36 | |||
| 37 | public function test_normalize_app_root_dir(): void |
||
| 47 |