spec\LdapTools\Security\Acl\DaclSpec::it_should_order_the_ace_canonically_if_specified PHP Метод

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

    function it_should_order_the_ace_canonically_if_specified()
    {
        $this->beConstructedWith(null);
        $deny = (new Ace('D'))->setTrustee(new SID('PS'));
        $allow = (new Ace('A'))->setTrustee(new SID('PS'));
        $denyObj = (new Ace('OD'))->setTrustee(new SID('PS'));
        $allowObj = (new Ace('OA'))->setTrustee(new SID('PS'));
        $inherited = (new Ace('D'))->setTrustee(new SID('PS'));
        $inherited->getFlags()->add(AceFlags::FLAG['INHERITED']);
        $this->addAce($inherited, $allowObj, $allow, $deny, $denyObj);
        $this->canonicalize()->getAces()->shouldBeEqualTo([$denyObj, $deny, $allowObj, $allow, $inherited]);
    }