Skip to content

Latest commit

 

History

History
21 lines (16 loc) · 781 Bytes

File metadata and controls

21 lines (16 loc) · 781 Bytes

Using WireMock to serve issuer-uri

Our tests need to connect to a OpenID Connect provider to bootstrap the application context.

Recording with WireMock

We’ve previously ran WireMock in proxy mode to record the calls made to our Keycloak OpenID Connect provider:

java -jar wiremock-jre8-standalone-2.33.2.jar --record-mappings --proxy-all="http://localhost:8090"

The resulting mappings and __files can be found in this folder.

Running WireMock

To serve the recorded mappings with WireMock we can run the same jar:

java -jar wiremock-jre8-standalone-2.33.2.jar --port 8090

Verifying endpoint