This article is follow-up to the previous unit testing discussion. This time we explore how to formulate unit tests for a routine that has multiple correct solutions, so that the tests aren't bound to implementation details.
This article is an example-based discussion of how I approach unit testing an unordered list. It emphasizes the idea of writing tests for the functionality, not for the implementation.