Right, but why can't you use a proper assertion? This `expected` is completely against the idea of JUnit and Hamcrest...