fix: add content-type header for koreader-sync auth (#1016)
* test: add content-type assertion for user auth * fix: specify JSON content type in authorizeUser method Set content type to JSON for user authorization response.
This commit is contained in:
+1
@@ -36,6 +36,7 @@ class KoreaderControllerTest {
|
||||
when(koreaderService.authorizeUser()).thenReturn(ResponseEntity.ok(expected));
|
||||
ResponseEntity<Map<String, String>> resp = controller.authorizeUser();
|
||||
assertEquals(HttpStatus.OK, resp.getStatusCode());
|
||||
assertEquals(MediaType.APPLICATION_JSON, resp.getHeaders().getContentType());
|
||||
assertEquals(expected, resp.getBody());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user