Improve unit tests for some constraints