Fix cleanup and spelling issues with Group.t
This commit is contained in:
parent
4f2905645a
commit
8ab2dcca05
1 changed files with 6 additions and 4 deletions
10
t/Group.t
10
t/Group.t
|
|
@ -192,7 +192,7 @@ my $ldapProps = WebGUI::Test->getSmokeLDAPProps();
|
||||||
$session->db->setRow('ldapLink', 'ldapLinkId', $ldapProps, $ldapProps->{ldapLinkId});
|
$session->db->setRow('ldapLink', 'ldapLinkId', $ldapProps, $ldapProps->{ldapLinkId});
|
||||||
my $ldap = WebGUI::LDAPLink->new($session, $ldapProps->{ldapLinkId});
|
my $ldap = WebGUI::LDAPLink->new($session, $ldapProps->{ldapLinkId});
|
||||||
is($ldap->getValue("ldapLinkId"),$ldapProps->{ldapLinkId},'ldap link created properly');
|
is($ldap->getValue("ldapLinkId"),$ldapProps->{ldapLinkId},'ldap link created properly');
|
||||||
addToCleanup($ldap);
|
WebGUI::Test->addToCleanup($ldap);
|
||||||
|
|
||||||
my @shawshank;
|
my @shawshank;
|
||||||
|
|
||||||
|
|
@ -687,7 +687,8 @@ cmp_bag(
|
||||||
ok $localSession->user->isInGroup($localScratchGroup->getId), 'Local Visitor is in the scratch group';
|
ok $localSession->user->isInGroup($localScratchGroup->getId), 'Local Visitor is in the scratch group';
|
||||||
|
|
||||||
$remoteSession->stow->delete('isInGroup');
|
$remoteSession->stow->delete('isInGroup');
|
||||||
ok !$remoteSession->user->isInGroup($localScratchGroup->getId), 'Remove Visitor is not in the scratch group, even though a different Visitor passed';
|
$localScratchGroup->clearCaches;
|
||||||
|
ok !$remoteSession->user->isInGroup($localScratchGroup->getId), 'Remote Visitor is not in the scratch group, even though a different Visitor passed';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -765,7 +766,8 @@ foreach my $ipTest (@ipTests) {
|
||||||
ok $localSession->user->isInGroup($localIpGroup->getId), 'Local Visitor is in the group';
|
ok $localSession->user->isInGroup($localIpGroup->getId), 'Local Visitor is in the group';
|
||||||
|
|
||||||
$remoteSession->stow->delete('isInGroup');
|
$remoteSession->stow->delete('isInGroup');
|
||||||
ok !$remoteSession->user->isInGroup($localIpGroup->getId), 'Remove Visitor is not in the group, even though a different Visitor passed';
|
$localIpGroup->clearCaches;
|
||||||
|
ok !$remoteSession->user->isInGroup($localIpGroup->getId), 'Remote Visitor is not in the group, even though a different Visitor passed';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -840,7 +842,7 @@ ok(! WebGUI::Group->vitalGroup('27'), '... 27 is not vital');
|
||||||
# Normal group
|
# Normal group
|
||||||
my $happyDude = WebGUI::User->create( $session );
|
my $happyDude = WebGUI::User->create( $session );
|
||||||
$happyDude->username(" Happy Dude ");
|
$happyDude->username(" Happy Dude ");
|
||||||
addToCleanup( $happyDude );
|
WebGUI::Test->addToCleanup( $happyDude );
|
||||||
|
|
||||||
$gA->addUsers([ $happyDude->getId ]);
|
$gA->addUsers([ $happyDude->getId ]);
|
||||||
$gB->addUsers([ $happyDude->getId ]);
|
$gB->addUsers([ $happyDude->getId ]);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue