Mercurial > hg
comparison tests/test-nointerrupt.t @ 48186:6edc8800dbc3
dispatch: use detailed exit code 250 for keyboard interrupt
Among our users at Google, we're still seeing several percent of
commands fail with exit code 255. I suspect keyboard interrupts is an
important remaining reason.
This is a resend of D10086 with some fixes for pager handling added
ahead of it.
Differential Revision: https://phab.mercurial-scm.org/D11628
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Tue, 02 Mar 2021 09:33:25 -0800 |
parents | 8892f604e242 |
children | 8c34edb1ad10 |
comparison
equal
deleted
inserted
replaced
48185:2f2107c01dee | 48186:6edc8800dbc3 |
---|---|
64 Test ctrl-c | 64 Test ctrl-c |
65 $ rm -f $SYNC_FILE $DONE_FILE | 65 $ rm -f $SYNC_FILE $DONE_FILE |
66 $ sh -c "../send-signal.sh INT" & | 66 $ sh -c "../send-signal.sh INT" & |
67 $ hg wait-signal | 67 $ hg wait-signal |
68 interrupted! | 68 interrupted! |
69 [255] | 69 [250] |
70 | 70 |
71 $ cat >> $HGRCPATH << EOF | 71 $ cat >> $HGRCPATH << EOF |
72 > [experimental] | 72 > [experimental] |
73 > nointerrupt = yes | 73 > nointerrupt = yes |
74 > EOF | 74 > EOF |
75 | 75 |
76 $ rm -f $SYNC_FILE $DONE_FILE | 76 $ rm -f $SYNC_FILE $DONE_FILE |
77 $ sh -c "../send-signal.sh INT" & | 77 $ sh -c "../send-signal.sh INT" & |
78 $ hg wait-signal | 78 $ hg wait-signal |
79 interrupted! | 79 interrupted! |
80 [255] | 80 [250] |
81 | 81 |
82 $ cat >> $HGRCPATH << EOF | 82 $ cat >> $HGRCPATH << EOF |
83 > [experimental] | 83 > [experimental] |
84 > nointerrupt-interactiveonly = False | 84 > nointerrupt-interactiveonly = False |
85 > EOF | 85 > EOF |
89 $ hg wait-signal | 89 $ hg wait-signal |
90 shutting down cleanly | 90 shutting down cleanly |
91 press ^C again to terminate immediately (dangerous) | 91 press ^C again to terminate immediately (dangerous) |
92 end of unsafe operation | 92 end of unsafe operation |
93 interrupted! | 93 interrupted! |
94 [255] | 94 [250] |