Mercurial > hg
comparison tests/test-convert-svn-move.t @ 13141:6cfe17c19ba2
tests: add filtercr.py helper for progress tests
The two tests that used filtercr.py already used a slightly different
version, which explains why test-convert-svn-move.t changed after
switching to using $TESTDIR/filtercr.py.
author | Martin Geisler <mg@aragost.com> |
---|---|
date | Wed, 15 Dec 2010 16:29:46 +0100 |
parents | f139f34ba330 |
children | e9827c85c50b |
comparison
equal
deleted
inserted
replaced
13140:217ae7d5c8ee | 13141:6cfe17c19ba2 |
---|---|
167 > [progress] | 167 > [progress] |
168 > assume-tty = 1 | 168 > assume-tty = 1 |
169 > delay = 0 | 169 > delay = 0 |
170 > refresh = 0 | 170 > refresh = 0 |
171 > EOF | 171 > EOF |
172 $ cat > filtercr.py <<EOF | 172 |
173 > import sys, re | 173 $ hg convert svn-repo hg-progress 2>&1 | $TESTDIR/filtercr.py |
174 > for line in sys.stdin: | |
175 > line = re.sub(r'\r+[^\n]', lambda m: '\n' + m.group()[-1:], line) | |
176 > sys.stdout.write(line) | |
177 > EOF | |
178 | |
179 $ hg convert svn-repo hg-progress 2>&1 | python filtercr.py | |
180 | 174 |
181 scanning [ <=> ] 1 | 175 scanning [ <=> ] 1 |
182 scanning [ <=> ] 2 | 176 scanning [ <=> ] 2 |
183 scanning [ <=> ] 3 | 177 scanning [ <=> ] 3 |
184 scanning [ <=> ] 4 | 178 scanning [ <=> ] 4 |
247 4 clobber1 | 241 4 clobber1 |
248 3 clobber2 | 242 3 clobber2 |
249 2 adddb | 243 2 adddb |
250 1 branch | 244 1 branch |
251 0 clobberdir | 245 0 clobberdir |
246 |