Mercurial > hg
comparison tests/test-upgrade-repo.t @ 49199:575f3dedb69a
auto-upgrade: add a test case where the repository is already locked
This show the current behavior when the repository to auto-upgrade is already
locked.
The current behavior is to abort, which is probably not great. Now that we have
a proper test, we can think about the behavior we wants in a later tests.
Differential Revision: https://phab.mercurial-scm.org/D12618
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Tue, 05 Apr 2022 04:45:48 +0200 |
parents | 1c233af99316 |
children | 71774d799de7 |
comparison
equal
deleted
inserted
replaced
49198:a68b37524d50 | 49199:575f3dedb69a |
---|---|
2074 $ hg debugformat -R auto-upgrade | grep dirstate-v2 | 2074 $ hg debugformat -R auto-upgrade | grep dirstate-v2 |
2075 dirstate-v2: yes | 2075 dirstate-v2: yes |
2076 | 2076 |
2077 $ chmod -R u+w auto-upgrade | 2077 $ chmod -R u+w auto-upgrade |
2078 | 2078 |
2079 Attempting Auto-upgrade on a locked repository | |
2080 ---------------------------------------------- | |
2081 | |
2082 $ hg -R auto-upgrade debuglock --set-lock --quiet & | |
2083 $ echo $! >> $DAEMON_PIDS | |
2084 $ $RUNTESTDIR/testlib/wait-on-file 10 auto-upgrade/.hg/store/lock | |
2085 $ hg status -R auto-upgrade \ | |
2086 > --config format.use-dirstate-v2.automatic-upgrade-of-mismatching-repositories=yes \ | |
2087 > --config format.use-dirstate-v2=no | |
2088 abort: repository auto-upgrade: timed out waiting for lock held by 'brunhoff/effffffc:1215708' | |
2089 [20] | |
2090 $ hg debugformat -R auto-upgrade | grep dirstate-v2 | |
2091 dirstate-v2: yes | |
2092 | |
2093 $ killdaemons.py |