@Test
public void testJsonDeserializeWithArraysAsStrings() throws Exception {
// Collection values can be deserialized from space or comma-separated lists
String value = "{\"foo\":\"bar\",\"client_id\":\"foo\",\"scope\":\"bar foo\",\"authorized_grant_types\":\"authorization_code\",\"authorities\":\"ROLE_USER,ROLE_ADMIN\"}";
BaseClientDetails details = new ObjectMapper().readValue(value, BaseClientDetails.class);
BaseClientDetails expected = new BaseClientDetails("foo", "", "foo,bar", "authorization_code", "ROLE_USER,ROLE_ADMIN");
expected.setAdditionalInformation(Collections.singletonMap("foo", (Object)"bar"));
assertEquals(expected, details);
}