mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-08-27 21:15:40 +02:00
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@94887 467b73ca-7a2a-4603-9d3b-597d59a354a9
18 lines
513 B
PHP
18 lines
513 B
PHP
<?php
|
|
/**
|
|
* @package sapphire
|
|
* @subpackage tests
|
|
*/
|
|
class PermissionRoleTest extends FunctionalTest {
|
|
static $fixture_file = 'sapphire/tests/security/PermissionRoleTest.yml';
|
|
|
|
function testDelete() {
|
|
$role = $this->objFromFixture('PermissionRole', 'role');
|
|
|
|
$role->delete();
|
|
|
|
$this->assertNull(DataObject::get('PermissionRole', "ID={$role->ID}"), 'Role is removed');
|
|
$this->assertNull(DataObject::get('PermissionRoleCode',"RoleID={$role->ID}"), 'Permissions removed along with the role');
|
|
}
|
|
}
|