diff options
author | Александр Кирюхин <alexander@kiryukhin.su> | 2018-01-19 19:03:26 +0300 |
---|---|---|
committer | Александр Кирюхин <alexander@kiryukhin.su> | 2018-01-19 19:03:26 +0300 |
commit | 8ea647570b87adda400e5a3ce6c91f4b51327a0d (patch) | |
tree | 7c5d328b41e64c3e78ac89c9674747346233c87a /tests/DotenvTest.php | |
parent | 47c9d580c6e799e72b6a70b22dd5107790b1d3e9 (diff) |
Diffstat (limited to 'tests/DotenvTest.php')
-rw-r--r-- | tests/DotenvTest.php | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/tests/DotenvTest.php b/tests/DotenvTest.php index 59dd8b0..757ce70 100644 --- a/tests/DotenvTest.php +++ b/tests/DotenvTest.php @@ -11,7 +11,6 @@ use NeonXP\Dotenv\Dotenv; use NeonXP\Dotenv\Exception\RuntimeException; use NeonXP\Dotenv\Loader\LoaderInterface; use NeonXP\Dotenv\Parser\ParserInterface; - use PHPUnit\Framework\TestCase; /** @@ -45,12 +44,8 @@ class DotenvTest extends TestCase { $dotenv = new Dotenv($this->mockLoader, $this->mockParser, $this->mockCompiler); - try { - $dotenv->get('TEST1'); - $this->assertTrue(false, 'Dotenv must throws exception if it not loaded'); - } catch (RuntimeException $exception) { - $this->assertTrue(true, 'Dotenv must throws exception if it not loaded'); - } + $this->expectException(RuntimeException::class); + $dotenv->get('TEST1'); $dotenv->load(); |