assertThat(value.toString(), is(equalTo("message")));
}
@Test
public void shouldUsePrefixCodesOnGetValueToString() throws Exception {
MessageSource messageSource = mock(MessageSource.class);
MessageSourceMap map = new TestMessageSourceMap(messageSource, new String[] { "a.", "b.", "c." });
Object value = map.get("x");
given(messageSource.getMessage(msr("a.x", "b.x", "c.x"), nullLocale())).willReturn("message");
assertThat(value.toString(), is(equalTo("message")));
}