@Test
public void shouldConnectAndKeepUsingUserPassMode() throws Exception {

  // given
  Properties properties = new Properties();
  properties.load(new FileInputStream(VALID_CONF_FILE_LOCATION));
  String user = (String) properties.get("username");
  String password = (String) properties.get("password");
  // when
  janbanery = janbaneryFactory.connectAndKeepUsing(user, password);
  // then, should use API key mode
  AuthProvider usedAuthProvider = janbanery.getAuthMode();
  assertThat(usedAuthProvider).isInstanceOf(UserPassAuthProvider.class);
}