spec\PhpSpec\Locator\PrioritizedResourceManagerSpec::it_does_not_allow_two_resources_for_the_same_spec PHP Метод

it_does_not_allow_two_resources_for_the_same_spec() публичный Метод

public it_does_not_allow_two_resources_for_the_same_spec ( $locator1, $locator2, PhpSpec\Locator\Resource $resource1, PhpSpec\Locator\Resource $resource2 )
$resource1 PhpSpec\Locator\Resource
$resource2 PhpSpec\Locator\Resource
    function it_does_not_allow_two_resources_for_the_same_spec($locator1, $locator2, Resource $resource1, Resource $resource2)
    {
        $this->registerLocator($locator1);
        $this->registerLocator($locator2);
        $resource1->getSpecClassname()->willReturn('Some\\Spec');
        $resource2->getSpecClassname()->willReturn('Some\\Spec');
        $locator1->getAllResources()->willReturn(array($resource1));
        $locator2->getAllResources()->willReturn(array($resource2));
        $this->locateResources('')->shouldReturn(array($resource2));
    }