Unit tests for the predicates

Change-Id: Ia0906ea11c67a462a5cbb752eeb9760080ab4e19