equal
deleted
inserted
replaced
134 |
134 |
135 $ dirstate_uuid_has_not_changed () { |
135 $ dirstate_uuid_has_not_changed () { |
136 > # Non-Rust always rewrites the whole dirstate |
136 > # Non-Rust always rewrites the whole dirstate |
137 > if [ $# -eq 1 ] || ([ -n "$HGMODULEPOLICY" ] && [ -z "${HGMODULEPOLICY##*rust*}" ]) || [ -n "$RHG_INSTALLED_AS_HG" ]; then |
137 > if [ $# -eq 1 ] || ([ -n "$HGMODULEPOLICY" ] && [ -z "${HGMODULEPOLICY##*rust*}" ]) || [ -n "$RHG_INSTALLED_AS_HG" ]; then |
138 > test $current_uid = $(find_dirstate_uuid) |
138 > test $current_uid = $(find_dirstate_uuid) |
|
139 > else |
|
140 > echo "not testing because using Python implementation" |
139 > fi |
141 > fi |
140 > } |
142 > } |
141 |
143 |
142 $ cd .. |
144 $ cd .. |
143 $ hg init append-mostly |
145 $ hg init append-mostly |
154 |
156 |
155 $ hg st |
157 $ hg st |
156 $ dirstate_data_files | wc -l |
158 $ dirstate_data_files | wc -l |
157 *1 (re) |
159 *1 (re) |
158 $ dirstate_uuid_has_not_changed |
160 $ dirstate_uuid_has_not_changed |
|
161 not testing because using Python implementation (no-rust no-rhg !) |
159 |
162 |
160 Trigger an append with a small change |
163 Trigger an append with a small change |
161 |
164 |
162 $ echo "modified" > dir2/f |
165 $ echo "modified" > dir2/f |
163 $ hg st |
166 $ hg st |
164 M dir2/f |
167 M dir2/f |
165 $ dirstate_data_files | wc -l |
168 $ dirstate_data_files | wc -l |
166 *1 (re) |
169 *1 (re) |
167 $ dirstate_uuid_has_not_changed |
170 $ dirstate_uuid_has_not_changed |
|
171 not testing because using Python implementation (no-rust no-rhg !) |
168 |
172 |
169 Unused bytes counter is non-0 when appending |
173 Unused bytes counter is non-0 when appending |
170 $ touch file |
174 $ touch file |
171 $ hg add file |
175 $ hg add file |
172 $ current_uid=$(find_dirstate_uuid) |
176 $ current_uid=$(find_dirstate_uuid) |
176 M dir2/f |
180 M dir2/f |
177 A file |
181 A file |
178 $ dirstate_data_files | wc -l |
182 $ dirstate_data_files | wc -l |
179 *1 (re) |
183 *1 (re) |
180 $ dirstate_uuid_has_not_changed |
184 $ dirstate_uuid_has_not_changed |
|
185 not testing because using Python implementation (no-rust no-rhg !) |
181 |
186 |
182 $ hg debugstate --docket | grep unused |
187 $ hg debugstate --docket | grep unused |
183 number of unused bytes: 0 (no-rust no-rhg !) |
188 number of unused bytes: 0 (no-rust no-rhg !) |
184 number of unused bytes: [1-9]\d* (re) (rhg no-rust !) |
189 number of unused bytes: [1-9]\d* (re) (rhg no-rust !) |
185 number of unused bytes: [1-9]\d* (re) (rust no-rhg !) |
190 number of unused bytes: [1-9]\d* (re) (rust no-rhg !) |