Mercurial > evolve
comparison tests/test-topic-mode.t @ 3770:eb928f5728c4
topic: suggest to clear a topic that becomes empty
We add a hint suggesting "hg topic --clear" when a topic becomes empty.
This usually happens when all its changesets get public, that is when
the user does a 'phase -p' or when they pull from a server. To
discriminate relevant cases for which we should display the hint (and
typically exclude explicit 'hg topic --clear' operation), we look for
the transaction "type" to only consider 'phase' or 'push' transaction.
In the latter case, the transaction name is not simply 'push-response'
but it also included the remote URL so we need to match on string
content.
author | Denis Laxalde <denis.laxalde@logilab.fr> |
---|---|
date | Wed, 23 May 2018 12:16:24 +0200 |
parents | 1bc4b0807c37 |
children | f3713d41b85b dd68ce259708 |
comparison
equal
deleted
inserted
replaced
3769:1bc4b0807c37 | 3770:eb928f5728c4 |
---|---|
242 | 242 |
243 Test a merge too | 243 Test a merge too |
244 | 244 |
245 $ hg phase --public -r . | 245 $ hg phase --public -r . |
246 active topic 'various-dove' is now empty | 246 active topic 'various-dove' is now empty |
247 (use 'hg topic --clear' to clear it if needed) | |
247 $ hg up default | 248 $ hg up default |
248 clearing empty topic "various-dove" | 249 clearing empty topic "various-dove" |
249 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | 250 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
250 $ hg log -G | 251 $ hg log -G |
251 @ changeset: 2:2d2acb6efad5 | 252 @ changeset: 2:2d2acb6efad5 |
305 | 306 |
306 Test a merge too | 307 Test a merge too |
307 | 308 |
308 $ hg phase --public -r . | 309 $ hg phase --public -r . |
309 active topic 'various-dove' is now empty | 310 active topic 'various-dove' is now empty |
311 (use 'hg topic --clear' to clear it if needed) | |
310 $ hg up default | 312 $ hg up default |
311 clearing empty topic "various-dove" | 313 clearing empty topic "various-dove" |
312 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | 314 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
313 $ hg log -G | 315 $ hg log -G |
314 @ changeset: 2:2d2acb6efad5 | 316 @ changeset: 2:2d2acb6efad5 |