File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 12
12
namespace Symfony \Component \Intl \Tests \Util ;
13
13
14
14
use PHPUnit \Framework \TestCase ;
15
+ use Symfony \Bridge \PhpUnit \ForwardCompatTestTrait ;
15
16
use Symfony \Component \Filesystem \Filesystem ;
16
17
use Symfony \Component \Intl \Exception \RuntimeException ;
17
18
use Symfony \Component \Intl \Util \GitRepository ;
21
22
*/
22
23
class GitRepositoryTest extends TestCase
23
24
{
25
+ use ForwardCompatTestTrait;
26
+
24
27
private $ targetDir ;
25
28
26
29
const REPO_URL = 'https://github.com/symfony/intl.git ' ;
@@ -39,11 +42,7 @@ protected function cleanup()
39
42
40
43
public function testItThrowsAnExceptionIfInitialisedWithNonGitDirectory ()
41
44
{
42
- if (method_exists ($ this , 'expectException ' )) {
43
- $ this ->expectException (RuntimeException::class);
44
- } else {
45
- $ this ->setExpectedException (RuntimeException::class);
46
- }
45
+ $ this ->expectException (RuntimeException::class);
47
46
48
47
@mkdir ($ this ->targetDir , 0777 , true );
49
48
You can’t perform that action at this time.
0 commit comments