fix ktest colorful output printing for non-ANSI terminals (issue #368)