Skip to content

Commit

Permalink
improve logs
Browse files Browse the repository at this point in the history
  • Loading branch information
mucsi96 committed Jul 30, 2023
1 parent a401692 commit ece7cf2
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ Converter<OAuth2AuthorizationCodeGrantRequest, MultiValueMap<String, String>> wi

Converter<Map<String, Object>, OAuth2AccessTokenResponse> withingsAccessTokenResponseConverter() {
return rawResponse -> {
log.info("Converting Withings access token response");
ObjectMapper mapper = new ObjectMapper();
WithingsGetAccessTokenResponse response = mapper.convertValue(rawResponse, new TypeReference<>() {
});
Expand Down
4 changes: 4 additions & 0 deletions test/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,7 @@ services:
volumes:
- ${WORKSPACE_ROOT}/test/reverse_proxy/traefik_static_conf.yml:/etc/traefik/traefik.yml
- ${WORKSPACE_ROOT}/test/reverse_proxy/traefik_dynamic_conf.yml:/etc/traefik/traefik_dynamic_conf.yml
networks:
default:
name: ${DOCKER_NETWORK}
external: true
2 changes: 2 additions & 0 deletions test/mock_withings/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ server.on("request", (request, response) => {
});
return response.end();
} else if (request.url.startsWith("/withings/v2/oauth2")) {
response.setHeader("Content-Type", "application/json");
return response.end(
JSON.stringify({
status: 0,
Expand All @@ -44,6 +45,7 @@ server.on("request", (request, response) => {
})
);
} else if (request.url.startsWith("/measure")) {
response.setHeader("Content-Type", "application/json");
return response.end(
JSON.stringify({
status: 0,
Expand Down

0 comments on commit ece7cf2

Please sign in to comment.