Added unit tests for predicates. Got predicates compiling, and passing on tests.