Move all sort functions into the same directory.

Largely to get around go pedantry so I can actually reduce some
duplication :)
Share common testing code.

Reduces duplication.
Fail on first error.

Not useful to have 1e6 failure messages.