Skip to content

Timestamp handling regression 2.7.12 -> 3.0.0 #2593

Closed
@lpandzic

Description

@lpandzic

Following code works fine on 2.7.12 but fails on 3.0.0:

@Test
void shouldNotFail() {
    // given
    var given = Map.<String, Object>of("lastAssigment", "2023-06-05T11:08:33.107451Z");

    // when
    var actual = BDDAssertions.catchRuntimeException(() -> mapper.fromHash(given));

    // then
    then(actual).isNull();
}
org.opentest4j.AssertionFailedError: 
expected: 
  null
 but was: 
  org.springframework.data.mapping.MappingException: Could not resolve subtype of [simple type, class java.lang.Object]: missing type id property '@class'
   at [Source: (byte[])"{"lastAssigment":"2023-06-05T11:08:33.107451Z"}"; line: 1, column: 47]

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions