Since we throw exception now in setActivity if activity is not defined\null I left both tests, the second one now checks whether we really throw exception :)