tests/test-narrow-expanddirstate.t
changeset 47740 28d5e05c139a
parent 41236 44a51c1c8e17
child 48363 6a454e7053a1
equal deleted inserted replaced
47739:6a06155dfaef 47740:28d5e05c139a
    72   >     ui.develwarn(b'expandnarrowspec called outside of transaction!')
    72   >     ui.develwarn(b'expandnarrowspec called outside of transaction!')
    73   >   repo.setnarrowpats(includes, excludes)
    73   >   repo.setnarrowpats(includes, excludes)
    74   >   narrowspec.copytoworkingcopy(repo)
    74   >   narrowspec.copytoworkingcopy(repo)
    75   >   newmatcher = narrowspec.match(repo.root, includes, excludes)
    75   >   newmatcher = narrowspec.match(repo.root, includes, excludes)
    76   >   added = matchmod.differencematcher(newmatcher, currentmatcher)
    76   >   added = matchmod.differencematcher(newmatcher, currentmatcher)
    77   >   for f in repo[b'.'].manifest().walk(added):
    77   >   with repo.dirstate.parentchange():
    78   >     repo.dirstate.normallookup(f)
    78   >       for f in repo[b'.'].manifest().walk(added):
       
    79   >           repo.dirstate.update_file(
       
    80   >               f,
       
    81   >               p1_tracked=True,
       
    82   >               wc_tracked=True,
       
    83   >               possibly_dirty=True,
       
    84   >           )
    79   > 
    85   > 
    80   > def reposetup(ui, repo):
    86   > def reposetup(ui, repo):
    81   >   class expandingrepo(repo.__class__):
    87   >   class expandingrepo(repo.__class__):
    82   >     def narrowmatch(self, *args, **kwargs):
    88   >     def narrowmatch(self, *args, **kwargs):
    83   >       with repo.wlock(), repo.lock(), repo.transaction(
    89   >       with repo.wlock(), repo.lock(), repo.transaction(