PhpUnitCompat::expectExceptionMessageMatches()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
cc 2
eloc 3
nc 2
nop 1
dl 0
loc 5
rs 10
c 2
b 0
f 0
1
<?php
2
3
/**
4
 * This file is part of the tarantool/queue package.
5
 *
6
 * (c) Eugene Leonovich <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
declare(strict_types=1);
13
14
namespace Tarantool\Queue\Tests;
15
16
/**
17
 * A compatibility layer for the legacy PHPUnit 7.
18
 */
19
trait PhpUnitCompat
20
{
21
    public function expectExceptionMessageMatches(string $regularExpression) : void
22
    {
23
        \is_callable(parent::class.'::expectExceptionMessageMatches')
24
            ? parent::expectExceptionMessageMatches(...func_get_args())
25
            : parent::expectExceptionMessageRegExp(...func_get_args());
26
    }
27
}
28