Skip to content

Commit 41767f5

Browse files
committed
Fix deprecated phpunit annotation
1 parent 3f4fdfb commit 41767f5

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

Tests/DotenvTest.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,14 @@
1212
namespace Symfony\Component\Dotenv\Tests;
1313

1414
use PHPUnit\Framework\TestCase;
15+
use Symfony\Bridge\PhpUnit\ForwardCompatTestTrait;
1516
use Symfony\Component\Dotenv\Dotenv;
1617
use Symfony\Component\Dotenv\Exception\FormatException;
1718

1819
class DotenvTest extends TestCase
1920
{
21+
use ForwardCompatTestTrait;
22+
2023
/**
2124
* @dataProvider getEnvDataWithFormatErrors
2225
*/
@@ -200,11 +203,9 @@ public function testLoad()
200203
$this->assertSame('BAZ', $bar);
201204
}
202205

203-
/**
204-
* @expectedException \Symfony\Component\Dotenv\Exception\PathException
205-
*/
206206
public function testLoadDirectory()
207207
{
208+
$this->expectException('Symfony\Component\Dotenv\Exception\PathException');
208209
$dotenv = new Dotenv();
209210
$dotenv->load(__DIR__);
210211
}

0 commit comments

Comments
 (0)