comparison tests/test-tags.t @ 12375:02990e22150b

tests: require regexes in unified tests to be marked with " (re)" Consider this test: $ hg glog --template '{rev}:{node|short} "{desc}"\n' @ 2:20c4f79fd7ac "3" | | o 1:38f24201dcab "2" |/ o 0:2a18120dc1c9 "1" Because each line beginning with "|" can be compiled as a regular expression (equivalent to ".*|"), they will match any output. Similarly: $ echo foo The blank output line can be compiled as a regular expression and will also match any output. With this patch, none of the above output lines will be matched as regular expressions. A line must end in " (re)" in order to be matched as one. Lines are still matched literally first, so the following will pass: $ echo 'foo (re)' foo (re)
author Brodie Rao <brodie@bitheap.org>
date Wed, 22 Sep 2010 16:06:00 -0500
parents c01dc9087d9a
children 97ffc68f71d3
comparison
equal deleted inserted replaced
12374:4e7dd28db0dd 12375:02990e22150b
297 bar 0:bbd179dfa0a7 297 bar 0:bbd179dfa0a7
298 298
299 Strip 1: expose an old head: 299 Strip 1: expose an old head:
300 300
301 $ hg --config extensions.mq= strip 5 301 $ hg --config extensions.mq= strip 5
302 saved backup bundle to .* 302 saved backup bundle to .* (re)
303 $ hg tags # partly stale cache 303 $ hg tags # partly stale cache
304 tip 5:735c3ca72986 304 tip 5:735c3ca72986
305 bar 1:78391a272241 305 bar 1:78391a272241
306 $ hg tags # up-to-date cache 306 $ hg tags # up-to-date cache
307 tip 5:735c3ca72986 307 tip 5:735c3ca72986
308 bar 1:78391a272241 308 bar 1:78391a272241
309 309
310 Strip 2: destroy whole branch, no old head exposed 310 Strip 2: destroy whole branch, no old head exposed
311 311
312 $ hg --config extensions.mq= strip 4 312 $ hg --config extensions.mq= strip 4
313 saved backup bundle to .* 313 saved backup bundle to .* (re)
314 $ hg tags # partly stale 314 $ hg tags # partly stale
315 tip 4:735c3ca72986 315 tip 4:735c3ca72986
316 bar 0:bbd179dfa0a7 316 bar 0:bbd179dfa0a7
317 $ rm -f .hg/tags.cache 317 $ rm -f .hg/tags.cache
318 $ hg tags # cold cache 318 $ hg tags # cold cache