From patchwork Tue Feb 26 02:39:49 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [stable] templatefilters: add missing import of _ From: Mads Kiilerich X-Patchwork-Id: 1047 Message-Id: To: mercurial-devel@selenic.com Date: Tue, 26 Feb 2013 03:39:49 +0100 # HG changeset patch # User Mads Kiilerich # Date 1361844560 -3600 # Branch stable # Node ID b1f0fd26bda704357708c73fdeb78f1b6f372238 # Parent 61c8327ced503bf7a1996337af711e0f4a58d4c0 templatefilters: add missing import of _ diff --git a/mercurial/templatefilters.py b/mercurial/templatefilters.py --- a/mercurial/templatefilters.py +++ b/mercurial/templatefilters.py @@ -5,6 +5,7 @@ # This software may be used and distributed according to the terms of the # GNU General Public License version 2 or any later version. +from i18n import _ import cgi, re, os, time, urllib import encoding, node, util, error import hbisect diff --git a/tests/test-template-engine.t b/tests/test-template-engine.t --- a/tests/test-template-engine.t +++ b/tests/test-template-engine.t @@ -44,4 +44,15 @@ 0 97e5f848f0936960273bbf75be6388cd0350a32b -1 0000000000000000000000000000000000000000 -1 0000000000000000000000000000000000000000 -1 0000000000000000000000000000000000000000 + $ hg tip --template '{fill(node, 7)}\n' + hg: parse error: fill expects an integer width + [255] + $ hg tip --template '{fill(node, "7")}\n' + ef4a3af + ceb5370 + e8500df + 6f7b191 + e48998e + 059af + $ cd ..