changeset 42714:6b71334f2540 stable

fncache: show that debugrebuildfncache is partly broken Differential Revision: https://phab.mercurial-scm.org/D6721
author Valentin Gatien-Baron <vgatien-baron@janestreet.com>
date Mon, 12 Aug 2019 13:22:27 -0400
parents 2c1a484ce4d4
children f59f8a5e9096
files tests/test-fncache.t
diffstat 1 files changed, 11 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/tests/test-fncache.t	Fri Aug 09 13:11:27 2019 +0200
+++ b/tests/test-fncache.t	Mon Aug 12 13:22:27 2019 -0400
@@ -435,6 +435,17 @@
   data/.bar.i
   data/foo.i
 
+debugrebuildfncache fails to recover from truncated line in fncache
+
+  $ printf a > .hg/store/fncache
+  $ hg debugrebuildfncache
+  abort: fncache does not ends with a newline
+  (use 'hg debugrebuildfncache' to rebuild the fncache)
+  [255]
+
+  $ cat .hg/store/fncache | sort
+  a
+
   $ cd ..
 
 Try a simple variation without dotencode to ensure fncache is ignorant of encoding