Fixes test and changes matcher from deprecated JUnit to hamcrest