File tree 1 file changed +2
-3
lines changed
src/test/java/cz/cvut/kbss/jsonld/deserialization/expanded
1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change 71
71
import static org .hamcrest .MatcherAssert .assertThat ;
72
72
import static org .hamcrest .Matchers .anyOf ;
73
73
import static org .hamcrest .Matchers .containsString ;
74
- import static org .hamcrest .Matchers .hasItem ;
75
74
import static org .hamcrest .Matchers .hasItems ;
76
75
import static org .hamcrest .Matchers .instanceOf ;
77
76
import static org .junit .jupiter .api .Assertions .assertEquals ;
@@ -346,7 +345,7 @@ void deserializationReturnsSubclassInstanceWhenTypesMatch() throws Exception {
346
345
this .sut = JsonLdDeserializer .createExpandedDeserializer (config );
347
346
final JsonArray input = readAndExpand ("objectWithDataProperties.json" );
348
347
final Person result = sut .deserialize (input , Person .class );
349
- assertTrue ( result instanceof User );
348
+ assertInstanceOf ( User . class , result );
350
349
}
351
350
352
351
@ Test
@@ -359,7 +358,7 @@ void deserializationSupportsPolymorphismForCollections() throws Exception {
359
358
final PolymorphicOrganization result = sut .deserialize (input , PolymorphicOrganization .class );
360
359
assertNotNull (result .employees );
361
360
assertEquals (3 , result .employees .size ());
362
- result .employees .forEach (e -> assertTrue ( e instanceof Employee ));
361
+ result .employees .forEach (e -> assertInstanceOf ( Employee . class , e ));
363
362
}
364
363
365
364
@ OWLClass (iri = Vocabulary .ORGANIZATION )
You can’t perform that action at this time.
0 commit comments