spec\PhpSpec\Matcher\ThrowMatcherSpec::it_accepts_a_method_during_which_an_error_specified_by_class_name_should_be_thrown PHP Method

it_accepts_a_method_during_which_an_error_specified_by_class_name_should_be_thrown() public method

    function it_accepts_a_method_during_which_an_error_specified_by_class_name_should_be_thrown(ArrayObject $arr)
    {
        if (!class_exists('\\Error')) {
            throw new SkippingException('The class Error, introduced in PHP 7, does not exist');
        }
        $arr->ksort()->willThrow('\\Error');
        $this->positiveMatch('throw', $arr, array('\\Error'))->during('ksort', array());
    }