public Map<String, LdapUserMapping> getUserMappings() {
    if (userMappings == null) {
      createUserMappings();
    }
    return userMappings;
  }
@Test
  public void getUserMappings_shouldCreateUserMappings_whenSingleLdapConfig() {
    Configuration configuration = generateSingleLdapSettingsWithUserAndGroupMapping().asConfig();
    LdapSettingsManager settingsManager = new LdapSettingsManager(configuration);

    Map<String, LdapUserMapping> result = settingsManager.getUserMappings();

    assertThat(result).hasSize(1).containsOnlyKeys("default");
    assertThat(result.get("default")).usingRecursiveComparison().isEqualTo(new LdapUserMapping(configuration, "ldap"));
  }