@Test
public void getExternalModuleJsonTranslation() {

    stubFor(get(urlPathMatching("/api/pes/locales/fr/pes.json"))
            .willReturn(ok("{ \"field\": \"value\" }")
                    .withHeader("Content-Type", "application/json")));
    given(modulesService.moduleHaveInstance(matches("pes"))).willReturn(true);
    given(discoveryUtils.getServiceUrlByName(matches("pes"))).willReturn("http://localhost:8089");
    String jsonTranslation = localesService.getJsonTranslation("pes", "fr", "pes");
    assertEquals(jsonTranslation, "{ \"field\": \"value\" }");
}