unit tests for compareValue validation