##// END OF EJS Templates
mq: use dirstateguard instead of dirstate.invalidate (qpush)...
mq: use dirstateguard instead of dirstate.invalidate (qpush) Before this patch, "mq.queue.apply()" uses "dirstate.invalidate()" as a kind of "restore .hg/dirstate to the original status" during afailure. But it just discards changes in memory, and doesn't actually restore ".hg/dirstate". Then, it can't work as expected, if "dirstate.write()" is executed while processing. This patch uses "dirstateguard" instead of "dirstate.invalidate()" to restore ".hg/dirstate" at failure even if "dirstate.write()" is executed before failure. This is a part of preparations to fix the issue that the recent (in memory) dirstate isn't visible to external processes (e.g. "precommit" hook).

File last commit:

r21391:cb158354 default
r24996:58308dde default
Show More
test-update-reverse.t
84 lines | 1.7 KiB | text/troff | Tads3Lexer
/ tests / test-update-reverse.t
Adrian Buehlmann
combine tests
r12279 $ hg init
$ touch a
$ hg add a
$ hg commit -m "Added a"
$ touch main
$ hg add main
$ hg commit -m "Added main"
$ hg checkout 0
0 files updated, 0 files merged, 1 files removed, 0 files unresolved
'main' should be gone:
$ ls
a
$ touch side1
$ hg add side1
$ hg commit -m "Added side1"
created new head
$ touch side2
$ hg add side2
$ hg commit -m "Added side2"
$ hg log
changeset: 3:91ebc10ed028
tag: tip
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: Added side2
changeset: 2:b932d7dbb1e1
parent: 0:c2eda428b523
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: Added side1
changeset: 1:71a760306caf
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: Added main
changeset: 0:c2eda428b523
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: Added a
$ hg heads
changeset: 3:91ebc10ed028
tag: tip
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: Added side2
changeset: 1:71a760306caf
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: Added main
$ ls
a
side1
side2
$ hg update --debug -C 1
resolving manifests
Siddharth Agarwal
manifestmerge: pass in branchmerge and force separately...
r18605 branchmerge: False, force: True, partial: False
Martin Geisler
merge: make debug output easier to read...
r15625 ancestor: 91ebc10ed028+, local: 91ebc10ed028+, remote: 71a760306caf
Mads Kiilerich
merge: process files in sorted order
r18360 side1: other deleted -> r
Mads Kiilerich
merge: change debug logging - test output changes but no real changes...
r21391 removing side1
Adrian Buehlmann
combine tests
r12279 side2: other deleted -> r
Bryan O'Sullivan
tests: update test output (will be folded into parent)
r18631 removing side2
FUJIWARA Katsunori
merge: increase safety of parallel updating/removing on icasefs...
r19095 updating: side2 2/3 files (66.67%)
Mads Kiilerich
merge: change debug logging - test output changes but no real changes...
r21391 main: remote created -> g
Bryan O'Sullivan
tests: update test output (will be folded into parent)
r18631 getting main
Adrian Buehlmann
combine tests
r12279 updating: main 3/3 files (100.00%)
1 files updated, 0 files merged, 2 files removed, 0 files unresolved
$ ls
a
main