Fixed equality bug in unit test