Neos\ContentRepository\Tests\Behavior\Features\Bootstrap\NodeAuthorizationTrait::iShouldGetFalseWhenAskingTheNodeAuthorizationServiceIfSettingThePropertyIsGranted PHP Метод

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

    public function iShouldGetFalseWhenAskingTheNodeAuthorizationServiceIfSettingThePropertyIsGranted($expectedResult, $propertyName)
    {
        if ($this->isolated === true) {
            $this->callStepInSubProcess(__METHOD__, sprintf(' %s %s %s %s', 'string', escapeshellarg(trim($expectedResult)), 'string', escapeshellarg($propertyName)));
        } else {
            if ($expectedResult === 'TRUE') {
                if ($this->nodeAuthorizationService->isGrantedToEditNodeProperty($this->currentNodes[0], $propertyName) !== true) {
                    Assert::fail('The node authorization service did not return TRUE!');
                }
            } else {
                if ($this->nodeAuthorizationService->isGrantedToEditNodeProperty($this->currentNodes[0], $propertyName) !== false) {
                    Assert::fail('The node authorization service did not return FALSE!');
                }
            }
        }
    }