Patchwork [02,of,25,RFC] shelve: wider check for successful abort in test

login
register
mail settings
Submitter Boris Feld
Date June 7, 2018, 2:11 p.m.
Message ID <95e65e2850cf1ebf3e74.1528380661@Laptop-Boris.lan>
Download mbox | patch
Permalink /patch/31996/
State New
Headers show

Comments

Boris Feld - June 7, 2018, 2:11 p.m.
# HG changeset patch
# User Boris Feld <boris.feld@octobus.net>
# Date 1527519311 -7200
#      Mon May 28 16:55:11 2018 +0200
# Node ID 95e65e2850cf1ebf3e741995ef830fd4943308a6
# Parent  40dcb51857e9abd5e9494f3511dcbff2650aa7ef
# EXP-Topic graftshelve
# Available At https://bitbucket.org/octobus/mercurial-devel/
#              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r 95e65e2850cf
shelve: wider check for successful abort in test

The test was previously focusing on checking that the "sub-rebase" aborted
properly. Since rebase is an implementation details we should also check for
other messages.

Differential Revision: https://phab.mercurial-scm.org/D3686

Patch

diff --git a/tests/test-shelve.t b/tests/test-shelve.t
--- a/tests/test-shelve.t
+++ b/tests/test-shelve.t
@@ -1289,8 +1289,16 @@  Try again but with a corrupted shelve st
   [1]
   $ sed 's/ae8c668541e8/123456789012/' .hg/shelvedstate > ../corrupt-shelvedstate
   $ mv ../corrupt-shelvedstate .hg/histedit-state
-  $ hg unshelve --abort 2>&1 | grep 'rebase aborted'
+  $ hg unshelve --abort 2>&1 | grep 'aborted'
   rebase aborted
+  unshelve of 'default-01' aborted
+  $ hg summary
+  parent: 0:ae8c668541e8 tip
+   root
+  branch: default
+  commit: 1 modified, 1 unknown
+  update: (current)
+  phases: 1 draft
   $ hg up -C .
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved