Added some more tests for edge conditions.
While trying to write a better version I found some of the
tests didn't cover some edge conditions and they didn't
check the groups of numbers were not reversed
or shuffled around.