Multiple correct results with Hamcrest (is there an or-matcher?)
marcos is right, but you have a couple other options as well. First of all, there is an either/or:
assertThat(result, either(is(1)).or(is(2)));
but if you have more than two items it would probably get unwieldy. Plus, the typechecker gets weird on stuff like that sometimes. For your case, you could do:
assertThat(result, isOneOf(1, 2, 3))
or if you already have your options in an array/Collection:
assertThat(result, isIn(theCollection))
See also Javadoc.