AcControllerResourceTest::testShouldNotLoadThroughParentResourceIfInstanceIsntLoadedWhenShallow PHP Метод

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

Should not load through parent resource if instance isn't loaded when shallow
    public function testShouldNotLoadThroughParentResourceIfInstanceIsntLoadedWhenShallow()
    {
        $projectAttributes = ['id' => 2];
        $project = $this->buildModel('Project', $projectAttributes);
        $this->params = array_merge($this->params, array_merge(['action' => 'show', 'id' => $project->id]));
        $resource = new Efficiently\AuthorityController\ControllerResource($this->controller, ['through' => 'category', 'shallow' => true]);
        $resource->loadResource();
        $this->assertEquals($this->getProperty($this->controller, 'project'), $project);
    }
AcControllerResourceTest