Don't assume terminal availability in ANSI doctests
Merge pull request #1261 from alco/ansi-doctest

Don't assume terminal availability in ANSI doctests