tests:asciimap: fix test on Python 3

Patching print() is really rather subtle. Instead of patching print
directly, patch sys.stdio.write.
asciimap: do not use print() for output

The fact that print() uses std.stdout.write() under the covers is
probably non-portable. Don't rely on this for the tests to pass.