Hacker Rank : Utopian Tree : adding unit tests against constraints