Add unit test for condition