[PATCH 1 of 1] test-treediscovery.t: fix escaping so test passes
Martin Geisler
mg at lazybytes.net
Thu May 5 12:31:21 CDT 2011
Augie Fackler <durin42 at gmail.com> writes:
> # HG changeset patch
> # User Augie Fackler <durin42 at gmail.com>
> # Date 1304613083 18000
> # Node ID b616cd67fdc088743b92ef3dfad8eae7f0f4750c
> # Parent e3dd3dcd6059d008f466ea31a2a0b43de9e8d47f
> test-treediscovery.t: fix escaping so test passes
>
> diff --git a/tests/test-treediscovery.t b/tests/test-treediscovery.t
> --- a/tests/test-treediscovery.t
> +++ b/tests/test-treediscovery.t
> @@ -3,7 +3,7 @@
> $ CAP=getbundle
> $ . "$TESTDIR/notcapable"
> $ echo '[ui]' >>$HGRCPATH
> - $ echo 'logtemplate="{rev} {node|short}: {desc} {branches}\\n"' >>$HGRCPATH
> + $ echo 'logtemplate="{rev} {node|short}: {desc} {branches}\n"' >>$HGRCPATH
> $ echo '[extensions]' >>$HGRCPATH
> $ echo 'graphlog=' >>$HGRCPATH
Turns out that this makes the test fail when /bin/sh is dash... I just
pushed dc733eec9169 which says:
A '\n' on the command line is turned into a newline by dash, but kept
as-is by bash, which resulted in a syntax error in the config file.
Luckily, dash wont turn '\n' into a newline when it is part of a
here-doc, so we can write the config file using that technique.
--
Martin Geisler
Mercurial links: http://mercurial.ch/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20110505/e7979d28/attachment.pgp>
More information about the Mercurial-devel
mailing list