tests/test-walk.t
changeset 11903 a4cc9e6f41c3
parent 11799 ddebb6a690b4
child 12156 4c94b6d0fb1c
equal deleted inserted replaced
11902:3c9a5ed9b1e2 11903:a4cc9e6f41c3
   196   $ hg debugwalk beans/../.hg/data
   196   $ hg debugwalk beans/../.hg/data
   197   abort: path contains illegal component: .hg/data
   197   abort: path contains illegal component: .hg/data
   198   $ hg debugwalk beans/.hg
   198   $ hg debugwalk beans/.hg
   199   abort: path 'beans/.hg' is inside repo 'beans'
   199   abort: path 'beans/.hg' is inside repo 'beans'
   200 
   200 
   201 Don't know how to test absolute paths without always getting a false
   201 Test absolute paths:
   202 error.
   202 
   203 # hg debugwalk `pwd`/beans
   203   $ hg debugwalk `pwd`/beans
   204 # hg debugwalk `pwd`/..
   204   f  beans/black     beans/black
       
   205   f  beans/borlotti  beans/borlotti
       
   206   f  beans/kidney    beans/kidney
       
   207   f  beans/navy      beans/navy
       
   208   f  beans/pinto     beans/pinto
       
   209   f  beans/turtle    beans/turtle
       
   210   $ hg debugwalk `pwd`/..
       
   211   abort: .*/.. not under root
       
   212 
       
   213 Test patterns:
   205 
   214 
   206   $ hg debugwalk glob:\*
   215   $ hg debugwalk glob:\*
   207   f  fennel      fennel
   216   f  fennel      fennel
   208   f  fenugreek   fenugreek
   217   f  fenugreek   fenugreek
   209   f  fiddlehead  fiddlehead
   218   f  fiddlehead  fiddlehead
   210   f  glob:glob   glob:glob
   219   f  glob:glob   glob:glob
       
   220 
   211   $ hg debugwalk 'glob:**e'
   221   $ hg debugwalk 'glob:**e'
   212   f  beans/turtle                    beans/turtle
   222   f  beans/turtle                    beans/turtle
   213   f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
   223   f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
       
   224 
   214   $ hg debugwalk 're:.*[kb]$'
   225   $ hg debugwalk 're:.*[kb]$'
   215   f  beans/black    beans/black
   226   f  beans/black    beans/black
   216   f  fenugreek      fenugreek
   227   f  fenugreek      fenugreek
   217   f  glob:glob      glob:glob
   228   f  glob:glob      glob:glob
   218   f  mammals/skunk  mammals/skunk
   229   f  mammals/skunk  mammals/skunk
       
   230 
   219   $ hg debugwalk path:beans/black
   231   $ hg debugwalk path:beans/black
   220   f  beans/black  beans/black  exact
   232   f  beans/black  beans/black  exact
   221   $ hg debugwalk path:beans//black
   233   $ hg debugwalk path:beans//black
   222   f  beans/black  beans/black  exact
   234   f  beans/black  beans/black  exact
       
   235 
   223   $ hg debugwalk relglob:Procyonidae
   236   $ hg debugwalk relglob:Procyonidae
   224   $ hg debugwalk 'relglob:Procyonidae/**'
   237   $ hg debugwalk 'relglob:Procyonidae/**'
   225   f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
   238   f  mammals/Procyonidae/cacomistle  mammals/Procyonidae/cacomistle
   226   f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
   239   f  mammals/Procyonidae/coatimundi  mammals/Procyonidae/coatimundi
   227   f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon
   240   f  mammals/Procyonidae/raccoon     mammals/Procyonidae/raccoon