comparison tests/test-nested-repo @ 5141:d316124ebbea

Make audit_path more stringent. The following properties of a path are now checked for: - under top-level .hg - starts at the root of a windows drive - contains ".." - traverses a symlink (e.g. a/symlink_here/b) - inside a nested repository If any of these is true, the path is rejected. The check for traversing a symlink is arguably stricter than necessary; perhaps we should be checking for symlinks that point outside the repository.
author Bryan O'Sullivan <bos@serpentine.com>
date Fri, 10 Aug 2007 10:46:03 -0700
parents 890e285c52a1
children c7e8fe11f34a
comparison
equal deleted inserted replaced
5140:f6c520fd70cf 5141:d316124ebbea
2 2
3 hg init a 3 hg init a
4 cd a 4 cd a
5 hg init b 5 hg init b
6 echo x > b/x 6 echo x > b/x
7
7 echo '# should print nothing' 8 echo '# should print nothing'
9 hg add b
8 hg st 10 hg st
9 echo '# should print ? b/x' 11
12 echo '# should fail'
10 hg st b/x 13 hg st b/x
11
12 hg add b/x 14 hg add b/x
13 15
14 echo '# should print A b/x' 16 echo '# should arguably print nothing'
17 hg st b
18
19 echo a > a
20 hg ci -Ama a
21
22 echo '# should fail'
23 hg mv a b
15 hg st 24 hg st
16 echo '# should forget b/x'
17 hg revert --all
18 echo '# should print nothing'
19 hg st b