Code Duplication    Length = 10-10 lines in 3 locations

src/Assert.php 3 locations

@@ 606-615 (lines=10) @@
603
        }
604
    }
605
606
    public static function contains($value, $subString, $message = '')
607
    {
608
        if (false === strpos($value, $subString)) {
609
            static::reportInvalidArgument(sprintf(
610
                $message ?: 'Expected a value to contain %2$s. Got: %s',
611
                static::valueToString($value),
612
                static::valueToString($subString)
613
            ));
614
        }
615
    }
616
617
    public static function notContains($value, $subString, $message = '')
618
    {
@@ 617-626 (lines=10) @@
614
        }
615
    }
616
617
    public static function notContains($value, $subString, $message = '')
618
    {
619
        if (false !== strpos($value, $subString)) {
620
            static::reportInvalidArgument(sprintf(
621
                $message ?: '%2$s was not expected to be contained in a value. Got: %s',
622
                static::valueToString($value),
623
                static::valueToString($subString)
624
            ));
625
        }
626
    }
627
628
    public static function notWhitespaceOnly($value, $message = '')
629
    {
@@ 638-647 (lines=10) @@
635
        }
636
    }
637
638
    public static function startsWith($value, $prefix, $message = '')
639
    {
640
        if (0 !== strpos($value, $prefix)) {
641
            static::reportInvalidArgument(sprintf(
642
                $message ?: 'Expected a value to start with %2$s. Got: %s',
643
                static::valueToString($value),
644
                static::valueToString($prefix)
645
            ));
646
        }
647
    }
648
649
    public static function startsWithLetter($value, $message = '')
650
    {