Added unit tests for each of the patterns.