string: test cleanups

Tests printed too much output on broken string function
and the output was not entirely useful.

Added a new header file with some common logic for
printing buffers nicely.

In str* tests len now means string length (not buffer
size which was confusing).
15 files changed