WebGUI 8 doesn't do Basic Auth, and ldap tests were moved into a different file.
This commit is contained in:
parent
42ed112d1f
commit
a3266dea35
2 changed files with 0 additions and 63 deletions
|
|
@ -266,12 +266,4 @@ $mech->submit_form_ok(
|
|||
);
|
||||
$mech->base_is( $assetUrl, "We don't get redirected" );
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
# HTTP basic auth
|
||||
$mech = Test::WWW::Mechanize->new;
|
||||
$mech->get( $httpAuthUrl );
|
||||
$mech->content_contains( "Hello, $USERNAME", "We are greeted by name" );
|
||||
$mech->get( $httpAuthUrl . $asset->get('url') );
|
||||
$mech->content_contains( "ARTICLE", "We are shown the article" );
|
||||
|
||||
done_testing;
|
||||
|
|
|
|||
55
t/Group.t
55
t/Group.t
|
|
@ -155,61 +155,6 @@ my $getGroupsIn = $optionGroup->getGroupsIn();
|
|||
cmp_deeply($getGroupsIn, [], 'new: noAdmin prevents the admin group from being added to this group');
|
||||
$optionGroup->delete;
|
||||
|
||||
################################################################
|
||||
#
|
||||
# LDAP specific group properties
|
||||
# These tests have to be done on an isolated group that will NEVER
|
||||
# have getGroups called on it
|
||||
#
|
||||
################################################################
|
||||
|
||||
my $ldapProps = WebGUI::Test->getSmokeLDAPProps();
|
||||
$session->db->setRow('ldapLink', 'ldapLinkId', $ldapProps, $ldapProps->{ldapLinkId});
|
||||
my $ldap = WebGUI::LDAPLink->new($session, $ldapProps->{ldapLinkId});
|
||||
is($ldap->getValue("ldapLinkId"),$ldapProps->{ldapLinkId},'ldap link created properly');
|
||||
WebGUI::Test->addToCleanup($ldap);
|
||||
|
||||
my @shawshank;
|
||||
|
||||
foreach my $idx (0..$#ldapTests) {
|
||||
$shawshank[$idx] = WebGUI::User->new($session, "new");
|
||||
$shawshank[$idx]->username("shawshank$idx");
|
||||
$shawshank[$idx]->authMethod("LDAP");
|
||||
my $auth = $shawshank[$idx]->authInstance;
|
||||
$auth->saveParams($shawshank[$idx]->getId,$shawshank[$idx]->authMethod,{
|
||||
connectDN => $ldapTests[$idx]->{dn},
|
||||
ldapConnection => $ldap->getValue("ldapLinkId"),
|
||||
ldapUrl => $ldap->getValue("ldapUrl"),
|
||||
});
|
||||
}
|
||||
|
||||
WebGUI::Test->addToCleanup(@shawshank);
|
||||
|
||||
my $lGroup = WebGUI::Group->new($session, 'new');
|
||||
|
||||
$lGroup->ldapGroup('cn=Convicts,o=shawshank');
|
||||
is($lGroup->ldapGroup(), 'cn=Convicts,o=shawshank', 'ldapGroup set and fetched correctly');
|
||||
|
||||
$lGroup->ldapGroupProperty('member');
|
||||
is($lGroup->ldapGroupProperty(), 'member', 'ldapGroup set and fetched correctly');
|
||||
|
||||
$lGroup->ldapLinkId($ldapProps->{ldapLinkId});
|
||||
is($lGroup->ldapLinkId(),$ldapProps->{ldapLinkId}, 'ldapLinkId set and fetched correctly');
|
||||
|
||||
is_deeply(
|
||||
[ (map { $lGroup->hasLDAPUser($_->getId) } @shawshank) ],
|
||||
[0, 1, 1],
|
||||
'shawshank user 2, and 3 found in lGroup users from LDAP'
|
||||
);
|
||||
|
||||
$lGroup->ldapRecursiveProperty('LDAP recursive property');
|
||||
is($lGroup->ldapRecursiveProperty(), 'LDAP recursive property', 'ldapRecursiveProperty set and fetched correctly');
|
||||
|
||||
$lGroup->ldapRecursiveFilter('LDAP recursive filter');
|
||||
is($lGroup->ldapRecursiveFilter(), 'LDAP recursive filter', 'ldapRecursiveFilter set and fetched correctly');
|
||||
|
||||
$lGroup->delete;
|
||||
|
||||
my $gid = $g->getId;
|
||||
is (length($gid), 22, "GroupId is proper length");
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue