jackson work

This commit is contained in:
eugenp 2014-07-23 01:02:08 +03:00
parent b5ed631612
commit a9c3c08670
2 changed files with 2 additions and 3 deletions

View File

@ -22,7 +22,7 @@ public class MyDtoSetter {
this.intValue = intValue;
}
public int anotherGetIntValue() {
public int alternativeGetIntValue() {
return intValue;
}

View File

@ -65,7 +65,7 @@ public class JacksonFieldUnitTest {
final MyDtoSetter dtoObject = mapper.readValue(jsonAsString, MyDtoSetter.class);
assertNotNull(dtoObject);
assertThat(dtoObject.anotherGetIntValue(), equalTo(1));
assertThat(dtoObject.alternativeGetIntValue(), equalTo(1));
}
@Test
@ -82,7 +82,6 @@ public class JacksonFieldUnitTest {
@Test
public final void givenDifferentAccessLevels_whenSetVisibility_thenSerializable() throws IOException {
final ObjectMapper mapper = new ObjectMapper();
mapper.setVisibility(PropertyAccessor.ALL, Visibility.NONE);
mapper.setVisibility(PropertyAccessor.FIELD, Visibility.ANY);
final MyDtoAccessLevel dtoObject = new MyDtoAccessLevel();