Mercurial > hg
annotate tests/test-inherit-mode.t @ 43252:32187ae9eeb3
copies: simplify the handling of merges
Instead of stacking copies for both parent on the head, we move copies outside
of the heap into a dedicated dictionary. The two side of merge can we merged
sooner, making the algorithm simpler.
This simplicity reflect in the heap structure and speed up the execution for
copies involving a large amount of merges.
Here are timing for perfpathcopies of multiple revision pairs.
- filelog: timing using filelog (with the introrev condition dropped)
- base: this series base
- before: the parent of this changeset
- after: this changeset
revision: large amount; added files: large amount; rename small amount; c3b14617fbd7 9ba6ab77fd29
filelog: ! wall 3.679613 comb 3.680000 user 3.580000 sys 0.100000 (median of 3)
base: ! wall 8.884369 comb 8.880000 user 8.850000 sys 0.030000 (median of 3)
before: ! wall 8.443747 comb 8.420000 user 8.410000 sys 0.010000 (median of 3)
after: ! wall 4.697917 comb 4.690000 user 4.660000 sys 0.030000 (median of 3)
revision: large amount; added files: small amount; rename small amount; c3b14617fbd7 f650a9b140d2
filelog: ! wall 0.003357 comb 0.010000 user 0.010000 sys 0.000000 (median of 781)
base: ! wall 12.398524 comb 12.400000 user 12.330000 sys 0.070000 (median of 3)
before: ! wall 10.852593 comb 10.850000 user 10.800000 sys 0.050000 (median of 3)
after: ! wall 6.750832 comb 6.750000 user 6.640000 sys 0.110000 (median of 3)
revision: large amount; added files: large amount; rename large amount; 08ea3258278e d9fa043f30c0
filelog: ! wall 2.754687 comb 2.760000 user 2.650000 sys 0.110000 (median of 4)
base: ! wall 1.423166 comb 1.420000 user 1.400000 sys 0.020000 (median of 8)
before: ! wall 1.068041 comb 1.060000 user 1.050000 sys 0.010000 (median of 10)
after: ! wall 1.045916 comb 1.050000 user 1.040000 sys 0.010000 (median of 10)
revision: small amount; added files: large amount; rename large amount; df6f7a526b60 a83dc6a2d56f
filelog: ! wall 1.552293 comb 1.550000 user 1.510000 sys 0.040000 (median of 6
base: ! wall 0.022662 comb 0.020000 user 0.020000 sys 0.000000 (median of 128)
before: ! wall 0.021111 comb 0.020000 user 0.020000 sys 0.000000 (median of 139)
after: ! wall 0.021577 comb 0.020000 user 0.020000 sys 0.000000 (median of 138)
revision: small amount; added files: large amount; rename small amount; 4aa4e1f8e19a 169138063d63
filelog: ! wall 1.500983 comb 1.500000 user 1.420000 sys 0.080000 (median of 7)
base: ! wall 0.006956 comb 0.010000 user 0.010000 sys 0.000000 (median of 392)
before: ! wall 0.004356 comb 0.010000 user 0.010000 sys 0.000000 (median of 675)
after: ! wall 0.004329 comb 0.000000 user 0.000000 sys 0.000000 (median of 682)
revision: small amount; added files: small amount; rename small amount; 4bc173b045a6 964879152e2e
filelog: ! wall 0.011745 comb 0.020000 user 0.020000 sys 0.000000 (median of 250)
base: ! wall 0.000156 comb 0.000000 user 0.000000 sys 0.000000 (median of 17180)
before: ! wall 0.000100 comb 0.000000 user 0.000000 sys 0.000000 (median of 26912)
after: ! wall 0.000105 comb 0.000000 user 0.000000 sys 0.000000 (median of 25689)
revision: medium amount; added files: large amount; rename medium amount; c95f1ced15f2 2c68e87c3efe
filelog: ! wall 3.228230 comb 3.230000 user 3.110000 sys 0.120000 (median of 4)
base: ! wall 0.997640 comb 1.000000 user 0.980000 sys 0.020000 (median of 10)
before: ! wall 0.778291 comb 0.780000 user 0.780000 sys 0.000000 (median of 13)
after: ! wall 0.706594 comb 0.710000 user 0.710000 sys 0.000000 (median of 15)
revision: medium amount; added files: medium amount; rename small amount; d343da0c55a8 d7746d32bf9d
filelog: ! wall 1.052501 comb 1.060000 user 1.040000 sys 0.020000 (median of 10
base: ! wall 0.214519 comb 0.220000 user 0.220000 sys 0.000000 (median of 45)
before: ! wall 0.160804 comb 0.160000 user 0.160000 sys 0.000000 (median of 62)
after: ! wall 0.163736 comb 0.160000 user 0.160000 sys 0.000000 (median of 60)
Differential Revision: https://phab.mercurial-scm.org/D7069
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 02 Oct 2019 13:43:27 -0400 |
parents | e4ac7e63c213 |
children | 3e91d9978bec |
rev | line source |
---|---|
22046
7a9cbb315d84
tests: replace exit 80 with #require
Matt Mackall <mpm@selenic.com>
parents:
20185
diff
changeset
|
1 #require unix-permissions |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
2 |
22046
7a9cbb315d84
tests: replace exit 80 with #require
Matt Mackall <mpm@selenic.com>
parents:
20185
diff
changeset
|
3 test that new files created in .hg inherit the permissions from .hg/store |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
4 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
5 $ mkdir dir |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
6 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
7 just in case somebody has a strange $TMPDIR |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
8 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
9 $ chmod g-s dir |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
10 $ cd dir |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
11 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
12 $ cat >printmodes.py <<EOF |
33989
266192d4666b
tests: update test-inherit-mode to pass our import checker
Augie Fackler <raf@durin42.com>
parents:
33721
diff
changeset
|
13 > from __future__ import absolute_import, print_function |
266192d4666b
tests: update test-inherit-mode to pass our import checker
Augie Fackler <raf@durin42.com>
parents:
33721
diff
changeset
|
14 > import os |
266192d4666b
tests: update test-inherit-mode to pass our import checker
Augie Fackler <raf@durin42.com>
parents:
33721
diff
changeset
|
15 > import sys |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
16 > |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
17 > allnames = [] |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
18 > isdir = {} |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
19 > for root, dirs, files in os.walk(sys.argv[1]): |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
20 > for d in dirs: |
12743
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12096
diff
changeset
|
21 > name = os.path.join(root, d) |
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12096
diff
changeset
|
22 > isdir[name] = 1 |
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12096
diff
changeset
|
23 > allnames.append(name) |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
24 > for f in files: |
12743
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12096
diff
changeset
|
25 > name = os.path.join(root, f) |
4c4aeaab2339
check-code: add 'no tab indent' check for unified tests
Adrian Buehlmann <adrian@cadifra.com>
parents:
12096
diff
changeset
|
26 > allnames.append(name) |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
27 > allnames.sort() |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
28 > for name in allnames: |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
29 > suffix = name in isdir and '/' or '' |
33989
266192d4666b
tests: update test-inherit-mode to pass our import checker
Augie Fackler <raf@durin42.com>
parents:
33721
diff
changeset
|
30 > print('%05o %s%s' % (os.lstat(name).st_mode & 0o7777, name, suffix)) |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
31 > EOF |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
32 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
33 $ cat >mode.py <<EOF |
33989
266192d4666b
tests: update test-inherit-mode to pass our import checker
Augie Fackler <raf@durin42.com>
parents:
33721
diff
changeset
|
34 > from __future__ import absolute_import, print_function |
266192d4666b
tests: update test-inherit-mode to pass our import checker
Augie Fackler <raf@durin42.com>
parents:
33721
diff
changeset
|
35 > import os |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
36 > import sys |
33721
24849d53697d
tests: clean up many print statements to be print functions instead
Augie Fackler <augie@google.com>
parents:
33427
diff
changeset
|
37 > print('%05o' % os.lstat(sys.argv[1]).st_mode) |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
38 > EOF |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
39 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
40 $ umask 077 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
41 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
42 $ hg init repo |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
43 $ cd repo |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
44 |
40794
d5622dfe4ba3
cache: create `wcache` directory at init time
Boris Feld <boris.feld@octobus.net>
parents:
40793
diff
changeset
|
45 $ chmod 0770 .hg/store .hg/cache .hg/wcache |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
46 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
47 before commit |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
48 store can be written by the group, other files cannot |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
49 store is setgid |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
50 |
39707
5abc47d4ca6b
tests: quote PYTHON usage
Matt Harbison <matt_harbison@yahoo.com>
parents:
39323
diff
changeset
|
51 $ "$PYTHON" ../printmodes.py . |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
52 00700 ./.hg/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
53 00600 ./.hg/00changelog.i |
40793
64cdfcc73706
cache: create `cache` directory at init time
Boris Feld <boris.feld@octobus.net>
parents:
40792
diff
changeset
|
54 00770 ./.hg/cache/ |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
55 00600 ./.hg/requires |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
56 00770 ./.hg/store/ |
40794
d5622dfe4ba3
cache: create `wcache` directory at init time
Boris Feld <boris.feld@octobus.net>
parents:
40793
diff
changeset
|
57 00770 ./.hg/wcache/ |
6113
8ca25589e960
try to fix test-inherit-mode on HFS+
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
6073
diff
changeset
|
58 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
59 $ mkdir dir |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
60 $ touch foo dir/bar |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
61 $ hg ci -qAm 'add files' |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
62 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
63 after commit |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
64 working dir files can only be written by the owner |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
65 files created in .hg can be written by the group |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
66 (in particular, store/**, dirstate, branch cache file, undo files) |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
67 new directories are setgid |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
68 |
39707
5abc47d4ca6b
tests: quote PYTHON usage
Matt Harbison <matt_harbison@yahoo.com>
parents:
39323
diff
changeset
|
69 $ "$PYTHON" ../printmodes.py . |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
70 00700 ./.hg/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
71 00600 ./.hg/00changelog.i |
15886
a5917346c72e
localrepo: update branchcache in a more reliable way
Mads Kiilerich <mads@kiilerich.com>
parents:
15483
diff
changeset
|
72 00770 ./.hg/cache/ |
20185
7d4219512823
branchmap: cache open/closed branch head information
Brodie Rao <brodie@sf.io>
parents:
18382
diff
changeset
|
73 00660 ./.hg/cache/branch2-served |
23786
7d63398fbfd1
branchmap: use revbranchcache when updating branch map
Mads Kiilerich <madski@unity3d.com>
parents:
22080
diff
changeset
|
74 00660 ./.hg/cache/rbc-names-v1 |
7d63398fbfd1
branchmap: use revbranchcache when updating branch map
Mads Kiilerich <madski@unity3d.com>
parents:
22080
diff
changeset
|
75 00660 ./.hg/cache/rbc-revs-v1 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
76 00660 ./.hg/dirstate |
33427
1bdafe1111ce
tests: add extra output for fsmonitor at checking under .hg
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
32940
diff
changeset
|
77 00660 ./.hg/fsmonitor.state (fsmonitor !) |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
78 00660 ./.hg/last-message.txt |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
79 00600 ./.hg/requires |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
80 00770 ./.hg/store/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
81 00660 ./.hg/store/00changelog.i |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
82 00660 ./.hg/store/00manifest.i |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
83 00770 ./.hg/store/data/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
84 00770 ./.hg/store/data/dir/ |
37416
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
85 00660 ./.hg/store/data/dir/bar.i (reporevlogstore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
86 00660 ./.hg/store/data/foo.i (reporevlogstore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
87 00770 ./.hg/store/data/dir/bar/ (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
88 00660 ./.hg/store/data/dir/bar/b80de5d138758541c5f05265ad144ab9fa86d1db (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
89 00660 ./.hg/store/data/dir/bar/index (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
90 00770 ./.hg/store/data/foo/ (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
91 00660 ./.hg/store/data/foo/b80de5d138758541c5f05265ad144ab9fa86d1db (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
92 00660 ./.hg/store/data/foo/index (reposimplestore !) |
37415
c2c8962a9465
simplestore: use a custom store for the simple store repo
Gregory Szorc <gregory.szorc@gmail.com>
parents:
33989
diff
changeset
|
93 00660 ./.hg/store/fncache (repofncache !) |
15483
9ae766f2f452
phases: set new commit in 1-phase
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
15455
diff
changeset
|
94 00660 ./.hg/store/phaseroots |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
95 00660 ./.hg/store/undo |
23904
d251da5e0e84
transaction: include backup file in the "undo" transaction
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
23786
diff
changeset
|
96 00660 ./.hg/store/undo.backupfiles |
15455
c6f87bdab2a1
phases: add rollback support
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
14266
diff
changeset
|
97 00660 ./.hg/store/undo.phaseroots |
26998
4414d500604f
localrepo: put bookmark move following commit in one transaction
Laurent Charignon <lcharignon@fb.com>
parents:
23904
diff
changeset
|
98 00660 ./.hg/undo.backup.dirstate |
14266
89e7d35e0ef0
fix bookmarks rollback behavior
Alexander Solovyov <alexander@solovyov.net>
parents:
13272
diff
changeset
|
99 00660 ./.hg/undo.bookmarks |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
100 00660 ./.hg/undo.branch |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
101 00660 ./.hg/undo.desc |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
102 00660 ./.hg/undo.dirstate |
40792
47e3f554df35
check-exec: write file in 'wcache' instead of 'cache'
Boris Feld <boris.feld@octobus.net>
parents:
40670
diff
changeset
|
103 00770 ./.hg/wcache/ |
47e3f554df35
check-exec: write file in 'wcache' instead of 'cache'
Boris Feld <boris.feld@octobus.net>
parents:
40670
diff
changeset
|
104 00711 ./.hg/wcache/checkisexec |
40831
59aed775610a
tests: stabilize test-inherit-mode.t on FreeBSD and macOS again
Augie Fackler <augie@google.com>
parents:
40794
diff
changeset
|
105 007.. ./.hg/wcache/checklink (re) |
40792
47e3f554df35
check-exec: write file in 'wcache' instead of 'cache'
Boris Feld <boris.feld@octobus.net>
parents:
40670
diff
changeset
|
106 00600 ./.hg/wcache/checklink-target |
41965
e4ac7e63c213
manifestcache: use `wcache` directory for manifest cache
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
41290
diff
changeset
|
107 00660 ./.hg/wcache/manifestfulltextcache (reporevlogstore !) |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
108 00700 ./dir/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
109 00600 ./dir/bar |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
110 00600 ./foo |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
111 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
112 $ umask 007 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
113 $ hg init ../push |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
114 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
115 before push |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
116 group can write everything |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
117 |
39707
5abc47d4ca6b
tests: quote PYTHON usage
Matt Harbison <matt_harbison@yahoo.com>
parents:
39323
diff
changeset
|
118 $ "$PYTHON" ../printmodes.py ../push |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
119 00770 ../push/.hg/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
120 00660 ../push/.hg/00changelog.i |
40793
64cdfcc73706
cache: create `cache` directory at init time
Boris Feld <boris.feld@octobus.net>
parents:
40792
diff
changeset
|
121 00770 ../push/.hg/cache/ |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
122 00660 ../push/.hg/requires |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
123 00770 ../push/.hg/store/ |
40794
d5622dfe4ba3
cache: create `wcache` directory at init time
Boris Feld <boris.feld@octobus.net>
parents:
40793
diff
changeset
|
124 00770 ../push/.hg/wcache/ |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
125 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
126 $ umask 077 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
127 $ hg -q push ../push |
6064
c608f67a87c0
add test-inherit-mode
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff
changeset
|
128 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
129 after push |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
130 group can still write everything |
6113
8ca25589e960
try to fix test-inherit-mode on HFS+
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
6073
diff
changeset
|
131 |
39707
5abc47d4ca6b
tests: quote PYTHON usage
Matt Harbison <matt_harbison@yahoo.com>
parents:
39323
diff
changeset
|
132 $ "$PYTHON" ../printmodes.py ../push |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
133 00770 ../push/.hg/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
134 00660 ../push/.hg/00changelog.i |
13272
5ccdca7df211
move tags.cache and branchheads.cache to a collected cache folder .hg/cache/
jfh <jason@jasonfharris.com>
parents:
12743
diff
changeset
|
135 00770 ../push/.hg/cache/ |
20185
7d4219512823
branchmap: cache open/closed branch head information
Brodie Rao <brodie@sf.io>
parents:
18382
diff
changeset
|
136 00660 ../push/.hg/cache/branch2-base |
29191
ad1ce3c7af72
localrepo: use dirstate savebackup instead of handling dirstate file manually
Mateusz Kwapich <mitrandir@fb.com>
parents:
26998
diff
changeset
|
137 00660 ../push/.hg/dirstate |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
138 00660 ../push/.hg/requires |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
139 00770 ../push/.hg/store/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
140 00660 ../push/.hg/store/00changelog.i |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
141 00660 ../push/.hg/store/00manifest.i |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
142 00770 ../push/.hg/store/data/ |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
143 00770 ../push/.hg/store/data/dir/ |
37416
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
144 00660 ../push/.hg/store/data/dir/bar.i (reporevlogstore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
145 00660 ../push/.hg/store/data/foo.i (reporevlogstore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
146 00770 ../push/.hg/store/data/dir/bar/ (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
147 00660 ../push/.hg/store/data/dir/bar/b80de5d138758541c5f05265ad144ab9fa86d1db (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
148 00660 ../push/.hg/store/data/dir/bar/index (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
149 00770 ../push/.hg/store/data/foo/ (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
150 00660 ../push/.hg/store/data/foo/b80de5d138758541c5f05265ad144ab9fa86d1db (reposimplestore !) |
7542e97c7867
tests: conditionalize tests for various repo features
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37415
diff
changeset
|
151 00660 ../push/.hg/store/data/foo/index (reposimplestore !) |
37415
c2c8962a9465
simplestore: use a custom store for the simple store repo
Gregory Szorc <gregory.szorc@gmail.com>
parents:
33989
diff
changeset
|
152 00660 ../push/.hg/store/fncache (repofncache !) |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
153 00660 ../push/.hg/store/undo |
23904
d251da5e0e84
transaction: include backup file in the "undo" transaction
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
23786
diff
changeset
|
154 00660 ../push/.hg/store/undo.backupfiles |
15455
c6f87bdab2a1
phases: add rollback support
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
14266
diff
changeset
|
155 00660 ../push/.hg/store/undo.phaseroots |
14266
89e7d35e0ef0
fix bookmarks rollback behavior
Alexander Solovyov <alexander@solovyov.net>
parents:
13272
diff
changeset
|
156 00660 ../push/.hg/undo.bookmarks |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
157 00660 ../push/.hg/undo.branch |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
158 00660 ../push/.hg/undo.desc |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
159 00660 ../push/.hg/undo.dirstate |
40794
d5622dfe4ba3
cache: create `wcache` directory at init time
Boris Feld <boris.feld@octobus.net>
parents:
40793
diff
changeset
|
160 00770 ../push/.hg/wcache/ |
6113
8ca25589e960
try to fix test-inherit-mode on HFS+
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
6073
diff
changeset
|
161 |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
162 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
163 Test that we don't lose the setgid bit when we call chmod. |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
164 Not all systems support setgid directories (e.g. HFS+), so |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
165 just check that directories have the same mode. |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
166 |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
167 $ cd .. |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
168 $ hg init setgid |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
169 $ cd setgid |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
170 $ chmod g+rwx .hg/store |
16225
7cf8de5a82d8
tests: ignore the return code of chmod in test-inherit-mode
Javi Merino <cibervicho@gmail.com>
parents:
16025
diff
changeset
|
171 $ chmod g+s .hg/store 2> /dev/null || true |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
172 $ mkdir dir |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
173 $ touch dir/file |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
174 $ hg ci -qAm 'add dir/file' |
39707
5abc47d4ca6b
tests: quote PYTHON usage
Matt Harbison <matt_harbison@yahoo.com>
parents:
39323
diff
changeset
|
175 $ storemode=`"$PYTHON" ../mode.py .hg/store` |
5abc47d4ca6b
tests: quote PYTHON usage
Matt Harbison <matt_harbison@yahoo.com>
parents:
39323
diff
changeset
|
176 $ dirmode=`"$PYTHON" ../mode.py .hg/store/data/dir` |
12096
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
177 $ if [ "$storemode" != "$dirmode" ]; then |
bb69460e9d2d
tests: unify test-inherit-mode
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
6301
diff
changeset
|
178 > echo "$storemode != $dirmode" |
16912
6ef3107c661e
tests: cleanup of tests that got lost in their own nested directories
Mads Kiilerich <mads@kiilerich.com>
parents:
16225
diff
changeset
|
179 > fi |
6ef3107c661e
tests: cleanup of tests that got lost in their own nested directories
Mads Kiilerich <mads@kiilerich.com>
parents:
16225
diff
changeset
|
180 $ cd .. |
6ef3107c661e
tests: cleanup of tests that got lost in their own nested directories
Mads Kiilerich <mads@kiilerich.com>
parents:
16225
diff
changeset
|
181 |
6ef3107c661e
tests: cleanup of tests that got lost in their own nested directories
Mads Kiilerich <mads@kiilerich.com>
parents:
16225
diff
changeset
|
182 $ cd .. # g-s dir |