tests/test-status-eacces.t
author Arseniy Alekseyev <aalekseyev@janestreet.com>
Tue, 09 Apr 2024 11:12:24 +0100
changeset 51602 68929cf3c0c6
parent 50323 86d2a28c018e
permissions -rw-r--r--
match: avoid rust fast path if the matcher was tampered with Otherwise the fast path does not respect the modifications made by the extension (concretely largefiles, but other extensions can start using that too)

#testcases dirstate-v1 dirstate-v2

#if dirstate-v2
  $ cat >> $HGRCPATH << EOF
  > [format]
  > use-dirstate-v2=1
  > [storage]
  > dirstate-v2.slow-path=allow
  > EOF
#endif


The proliferation of status implementations can be confusing:
- The pure python implementation:
(no-rhg pure !)
- The C implementation:
(no-rhg no-rust no-pure !)
- The two rust implementations:
(rhg !)
(no-rhg rust !)

  $ hg init repo1
  $ cd repo1
  $ mkdir d1
  $ touch d1/x
  $ hg commit -Am.
  adding d1/x
  $ touch d1/y
  $ chmod -r d1
  $ hg status
  d1: $EACCES$
  ! d1/x (rhg !)
  ! d1/x (no-rhg rust !)
  $ hg status
  d1: $EACCES$
  ! d1/x (rust !)
  ! d1/x (no-rust rhg !)
  $ chmod +r d1
  $ hg status
  ? d1/y

  $ touch d1/z
  $ hg status
  ? d1/y
  ? d1/z