public function testRemoveRuleById()
{
$acl = new Acl();
$user = new Role('User');
$page = new Resource('Page');
$rule1 = new Rule('View');
$rule2 = new Rule('View');
$rule3 = new Rule('View');
$acl->addRule($user, $page, $rule1, true);
$acl->addRule($user, $page, $rule2, true);
$acl->addRule($user, $page, $rule3, true);
$acl->removeRuleById('bad_id_test');
$this->assertAttributeCount(3, 'rules', $acl);
$acl->removeRuleById($rule1->getId());
$this->assertAttributeCount(2, 'rules', $acl);
$acl->removeRuleById($rule2->getId());
$acl->removeRuleById($rule3->getId());
$this->assertAttributeCount(0, 'rules', $acl);
}