@Parameters({"endSessionPath", "postLogoutRedirectUri"}) @Test(dependsOnMethods = "requestEndSessionStep2") public void requestEndSessionStep3(final String endSessionPath, final String postLogoutRedirectUri) throws Exception { String state = UUID.randomUUID().toString(); EndSessionRequest endSessionRequest = new EndSessionRequest(idToken, postLogoutRedirectUri, state); endSessionRequest.setSessionId(sessionId); Builder request = ResteasyClientBuilder.newClient() .target(url.toString() + endSessionPath + "?" + endSessionRequest.getQueryString()).request(); request.header("Content-Type", MediaType.APPLICATION_FORM_URLENCODED); Response response = request.get(); String entity = response.readEntity(String.class); showResponse("requestEndSessionStep3", response, entity); assertEquals(response.getStatus(), 200, "Unexpected response code."); assertNotNull(entity, "Unexpected html."); assertTrue(entity.contains(postLogoutRedirectUri)); assertTrue(entity.contains(postLogoutRedirectUri)); }
endSessionRequest1.setSessionId(authorizationResponse.getSessionId()); endSessionRequest2.setSessionId(authorizationResponse.getSessionId());
endSessionRequest1.setSessionId(authorizationResponse.getSessionId()); endSessionRequest2.setSessionId(authorizationResponse.getSessionId());
endSessionRequest.setSessionId(authorizationResponse.getSessionId());