# HG changeset patch # User Saurabh Singh # Date 1507057763 25200 # Node ID 1f5bd3e1a7fe9f068d6dfeff5f693fe706478020 # Parent 5385b76fd1fd25668d609eab31726449b96d7965 test-basic: make test compatible with chg The error codes returned when writing to /dev/full are different after the first failure with and without '--chg' option. Therefore, this commit conditionally handles the error codes as appropriate. Test Plan: Ran the test 'test-basic.t' with and without '--chg' option. Differential Revision: https://phab.mercurial-scm.org/D922 diff -r 5385b76fd1fd -r 1f5bd3e1a7fe tests/test-basic.t --- a/tests/test-basic.t Mon Oct 02 20:23:25 2017 -0700 +++ b/tests/test-basic.t Tue Oct 03 12:09:23 2017 -0700 @@ -31,7 +31,9 @@ $ hg status >/dev/full abort: No space left on device [255] +#endif +#if devfull no-chg $ hg status >/dev/full 2>&1 [1] @@ -39,6 +41,14 @@ [1] #endif +#if devfull chg + $ hg status >/dev/full 2>&1 + [255] + + $ hg status ENOENT 2>/dev/full + [255] +#endif + $ hg commit -m test This command is ancient: