Add NULL test to tree comparators
Add function to resolve random constant