annotate tests/test-hgk.t @ 21564:2e91d4964ecd stable

subrepo: make "_sanitize()" work "_sanitize()" was introduced by 224e96078708 on "stable" branch, but it has done nothing for sanitizing since 224e96078708. "_sanitize()" assumes "Visitor" design pattern: "os.walk()" should invoke specified function ("v" in this case) for each directory elements under specified path but "os.walk()" assumes "Iterator" design pattern: callers of it should drive loop to scan each directory elements under specified path by themselves with the returned generator object Because of this mismatching, "_sanitize()" just discards the generator object returned by "os.walk()" and does nothing for sanitizing. This patch makes "_sanitize()" work. This patch also changes the format of warning message to show each unlinked files, for multiple appearances of "potentially hostile .hg/hgrc".
author FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
date Thu, 08 May 2014 19:03:00 +0900
parents cf72fd8b3072
children 5fb1fc2e1281
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
12431
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
1 Minimal hgk check
6800
cc7114d96548 hgk: ctx.parents() problem introduced by 2d54e7c1e69d
Patrick Mezard <pmezard@gmail.com>
parents:
diff changeset
2
12431
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
3 $ echo "[extensions]" >> $HGRCPATH
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
4 $ echo "hgk=" >> $HGRCPATH
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
5 $ hg init repo
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
6 $ cd repo
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
7 $ echo a > a
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
8 $ hg ci -Am adda
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
9 adding a
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
10 $ hg debug-cat-file commit 0
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
11 tree a0c8bcbbb45c
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
12 parent 000000000000
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
13 author test 0 0
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
14 revision 0
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
15 branch default
18807
cf72fd8b3072 hgk: add support for phases
Andrew Shadura <bugzilla@tut.by>
parents: 17959
diff changeset
16 phase draft
12431
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
17
d911aa2b8570 tests: unify test-hgk
Matt Mackall <mpm@selenic.com>
parents: 6800
diff changeset
18 adda
16913
f2719b387380 tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents: 12431
diff changeset
19
f2719b387380 tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents: 12431
diff changeset
20 $ cd ..