use of org.jenkinsci.test.acceptance.po.User in project acceptance-test-harness by jenkinsci.
the class LdapPluginTest method custom_invalid_group_membership_filter.
@Test
public void custom_invalid_group_membership_filter() {
// Given
useLdapAsSecurityRealm(createDefaults(ldap.get()).groupMembershipStrategy(SearchForGroupsLdapGroupMembershipStrategy.class).groupMembershipStrategyParam("(member={0})"));
// When
Login login = jenkins.login();
login.doLogin("jenkins", "root");
User userJenkins = new User(jenkins, "jenkins");
// Then
assertThat(userJenkins, not(isMemberOf("ldap1")));
assertThat(userJenkins, not(isMemberOf("ldap2")));
}
use of org.jenkinsci.test.acceptance.po.User in project acceptance-test-harness by jenkinsci.
the class LdapPluginTest method resolve_email.
@Test
public void resolve_email() {
// Given
useLdapAsSecurityRealm(createDefaults(ldap.get()));
// When
Login login = jenkins.login();
login.doLogin("jenkins", "root");
// Then
assertThat(jenkins, hasLoggedInUser("jenkins"));
User u = new User(jenkins, "jenkins");
assertThat(u, mailAddressIs("jenkins@jenkins-ci.org"));
}
use of org.jenkinsci.test.acceptance.po.User in project acceptance-test-harness by jenkinsci.
the class LdapPluginTest method custom_display_name.
@Test
@Issue("JENKINS-18355")
public void custom_display_name() {
// Given
useLdapAsSecurityRealm(createDefaults(ldap.get()).displayNameAttributeName("cn"));
// When
Login login = jenkins.login();
login.doLogin("jenkins", "root");
User userJenkins = new User(jenkins, "jenkins");
// Then
assertThat(userJenkins, fullNameIs("Jenkins the Butler"));
}
Aggregations