aboutsummaryrefslogtreecommitdiff
path: root/tests/DotenvTest.php
diff options
context:
space:
mode:
authorАлександр Кирюхин <alexander@kiryukhin.su>2018-01-19 19:03:26 +0300
committerАлександр Кирюхин <alexander@kiryukhin.su>2018-01-19 19:03:26 +0300
commit8ea647570b87adda400e5a3ce6c91f4b51327a0d (patch)
tree7c5d328b41e64c3e78ac89c9674747346233c87a /tests/DotenvTest.php
parent47c9d580c6e799e72b6a70b22dd5107790b1d3e9 (diff)
Remove KeyValue objectHEADmaster
Diffstat (limited to 'tests/DotenvTest.php')
-rw-r--r--tests/DotenvTest.php9
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();