You don't have to have a test for both the type of the return value and the the value itself. You can just have one test that checks the value. It will fail if it's not an Integer anyway.