RepositoryService: implement RemoveRepository
- Apr 28, 2022
-
-
Georges Racinet authored
Closes #95 This is in advance of the HGitaly3 milestone, but needed for gitaly-backup (removal occurs before restoration). We don't attempt to provide the same level of locking as Gitaly does, both because this is not the best time to handle locking for mutation methods and because this is a special case, but we split the work into atomic rename and cleanup (cheap to implement). See also heptapod#534
-
- Apr 29, 2022
-
-
Georges Racinet authored
In the process, the `ServiceFixture` class gains a few more utilities to handle repositories directly and the cleanup code paths are now covered. Also an opportunity to use mercurial_testhelpers features that were introduced since the writing of many of these tests, such as `LocalRepoWrapper.load()`. Also applying general coding style that avoids bound variables (when reasonable).
-
Georges Racinet authored
This will help make common patterns more uniform. The `__init__` super dance is not the most elegant code ever written, but using classmethods wouldn't be so much of an improvement.
-
- Apr 28, 2022
-
-
Georges Racinet authored
The immediate need is to implement `RepositoryService.RemoveRepository()`, but there are other potential use cases, same as with Gitaly.
-
Georges Racinet authored
It will be reused soon for other purposes than finding a repository path
-