mardi 5 juillet 2016

can hamcrest "hasItem" get few matchers?

I saw this post

assertThat( myClass.getMyItems(), contains(
    hasProperty("foo", is("bar")), 
    hasProperty("name", is("bar"))
));

how can it work?

doesn't hasItem expect one matcher as an argument and not a list of matchers?

Aucun commentaire:

Enregistrer un commentaire