Code Duplication    Length = 9-9 lines in 2 locations

src/Assert.php 2 locations

@@ 1525-1533 (lines=9) @@
1522
     *
1523
     * @throws InvalidArgumentException
1524
     */
1525
    public static function methodExists($classOrObject, $method, $message = '')
1526
    {
1527
        if (!\method_exists($classOrObject, $method)) {
1528
            static::reportInvalidArgument(\sprintf(
1529
                $message ?: 'Expected the method %s to exist.',
1530
                static::valueToString($method)
1531
            ));
1532
        }
1533
    }
1534
1535
    /**
1536
     * @param string|object $classOrObject
@@ 1542-1550 (lines=9) @@
1539
     *
1540
     * @throws InvalidArgumentException
1541
     */
1542
    public static function methodNotExists($classOrObject, $method, $message = '')
1543
    {
1544
        if (\method_exists($classOrObject, $method)) {
1545
            static::reportInvalidArgument(\sprintf(
1546
                $message ?: 'Expected the method %s to not exist.',
1547
                static::valueToString($method)
1548
            ));
1549
        }
1550
    }
1551
1552
    /**
1553
     * @param array      $array