From 6a956d1d838a3634d75bbd756f8be25483704282 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20Cholewi=C5=84ski?= Date: Fri, 10 Apr 2015 12:25:00 +0200 Subject: [PATCH] Hack: change a doctest to avoid repr(object) in Py3k --- boltons/formatutils.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/boltons/formatutils.py b/boltons/formatutils.py index ad4db42..c8424c3 100644 --- a/boltons/formatutils.py +++ b/boltons/formatutils.py @@ -124,8 +124,13 @@ def get_format_args(fstr): arguments. Each element of the list includes the name and the nominal type of the field. - >>> get_format_args("{noun} is {1:d} years old{punct}") - ([(1, )], [('noun', ), ('punct', )]) + # >>> get_format_args("{noun} is {1:d} years old{punct}") + # ([(1, )], [('noun', ), ('punct', )]) + + # XXX: Py3k + >>> get_format_args("{noun} is {1:d} years old{punct}") == \ + ([(1, int)], [('noun', str), ('punct', str)]) + True """ # TODO: memoize formatter = Formatter()