# HG changeset patch # User Mads Kiilerich # Date 2014-12-31 13:45:02 # Node ID 97eb62b0f4a91cea78909e7098c6b069c3899f89 # Parent e3f30068d2ebdeb549ea0cd9fec76df2e6ef40bb tests: add test coverage for lfdirstate invalidation of linear update f72d73937853 introduced a significant performance regression: All largefiles are marked 'normallookup' in lfdirstate by linear (or noop) updates and has to be rehashed by the next command. To avoid such regressions, keep an eye on the dirstate content after a plain 'hg up'. diff --git a/tests/test-largefiles-update.t b/tests/test-largefiles-update.t --- a/tests/test-largefiles-update.t +++ b/tests/test-largefiles-update.t @@ -25,6 +25,21 @@ directory (and ".hg/largefiles/dirstate" $ hg commit -m '#2' created new head +Test that lfdirstate keeps track of last modification of largefiles and +prevents unnecessary hashing of content - also after linear/noop update + + $ sleep 1 + $ hg st + $ hg debugdirstate --large --nodate + n 644 7 large1 + n 644 13 large2 + $ hg up + 0 files updated, 0 files merged, 0 files removed, 0 files unresolved + $ hg debugdirstate --large --nodate + n 0 -1 large1 + n 0 -1 large2 +BAD: ^^ + Test that "hg merge" updates largefiles from "other" correctly (getting largefiles from "other" normally)