@Test
public void getRpId_without_rpId_and_rpIdProvider_set(){

    MockHttpServletRequest request = new MockHttpServletRequest();
    request.setScheme("https");
    request.setServerName("origin.example.com");
    request.setServerPort(443);
    Challenge mockChallenge = new DefaultChallenge();
    when(challengeRepository.loadOrGenerateChallenge(request)).thenReturn(mockChallenge);
    ServerPropertyProviderImpl serverPropertyProviderImpl = new ServerPropertyProviderImpl(challengeRepository);
    assertThat(serverPropertyProviderImpl.getRpId(request)).isEqualTo("origin.example.com");
}