spec\PhpSpec\Laravel\Runner\Maintainer\LaravelMaintainerSpec::let PHP Method

let() public method

public let ( Laravel $laravel, ExampleNode $example, PhpSpec\Specification $context )
$laravel PhpSpec\Laravel\Util\Laravel
$example PhpSpec\Loader\Node\ExampleNode
$context PhpSpec\Specification
    function let(Laravel $laravel, ExampleNode $example, Specification $context)
    {
        $this->beConstructedWith($laravel);
        $p = new Prophet();
        $this->refMethod = $p->prophesize('ReflectionMethod');
        $this->refMethod->invokeArgs(Argument::type('PhpSpec\\Specification'), Argument::type('array'))->shouldBeCalled();
        $refClass = $p->prophesize('ReflectionClass');
        $refClass->hasMethod('setLaravel')->willReturn(true);
        $refClass->hasMethod('setLaravel')->shouldBeCalled();
        $refClass->getMethod('setLaravel')->willReturn($this->refMethod->reveal());
        $refClass->getMethod('setLaravel')->shouldBeCalled();
        $specNode = $p->prophesize('PhpSpec\\Loader\\Node\\SpecificationNode');
        $specNode->getClassReflection()->willReturn($refClass->reveal());
        $example->getSpecification()->willReturn($specNode->reveal());
    }