/**
  * @dataProvider constructor_provider
  */
 public function test_it_should_set_some_properties_when_we_construct_it($name, $status, $parsed)
 {
     $permission = new Permission($name, $status);
     $this->assertEquals($name, $permission->getName());
     $this->assertEquals($status, $permission->getStatus());
     $this->assertEquals($parsed, $permission->getParsedStatus());
 }
 public function findInPermissions(Permission $permission)
 {
     $this->is_baned = false;
     $simplified = $permission->simplifyPermission();
     foreach ($this->permissions as $stored_permission) {
         $stored_permission_simplified = $stored_permission->simplifyPermission();
         if ($simplified['name'] == $stored_permission_simplified['name']) {
             $this->is_baned = true;
             return true;
         }
     }
     return false;
 }