tests/test-ui-color.py
author Mads Kiilerich <mads@kiilerich.com>
Tue, 28 Sep 2010 02:58:00 +0200
changeset 12579 aa1faedeac5a
parent 11732 386e56ecfb78
child 12865 4c50552fc9bc
permissions -rw-r--r--
graphlog: style with header and footer (issue2395) The glog command didn't emit header and footer from the style, as demonstrated by "hg glog --style xml". Asciiart combined with xml markup hardly makes sense, but header and footer might however be useful for adding for example html pre tags around the graph.

#!/usr/bin/env python

from hgext import color

# ensure errors aren't buffered
testui = color.colorui()
testui.pushbuffer()
testui.write('buffered\n')
testui.warn('warning\n')
testui.write_err('error\n')
print repr(testui.popbuffer())