tests/test-subrepo-svn.t
changeset 16073 b254f827b7a6
parent 15607 fab28a577a38
child 16451 9c431cfdca12
equal deleted inserted replaced
16072:bcb973abcc0b 16073:b254f827b7a6
    67   $ svn co --quiet "$SVNREPO"/src s
    67   $ svn co --quiet "$SVNREPO"/src s
    68   $ mkdir subdir
    68   $ mkdir subdir
    69   $ svn co --quiet "$SVNREPO"/src subdir/s
    69   $ svn co --quiet "$SVNREPO"/src subdir/s
    70   $ hg add .hgsub
    70   $ hg add .hgsub
    71   $ hg ci -m1
    71   $ hg ci -m1
    72   committing subrepository s
       
    73   committing subrepository subdir/s
       
    74 
    72 
    75 make sure we avoid empty commits (issue2445)
    73 make sure we avoid empty commits (issue2445)
    76 
    74 
    77   $ hg sum
    75   $ hg sum
    78   parent: 1:* tip (glob)
    76   parent: 1:* tip (glob)
   430   $ cd rebaserepo
   428   $ cd rebaserepo
   431   $ svn co -r5 --quiet "$SVNREPO"/src s
   429   $ svn co -r5 --quiet "$SVNREPO"/src s
   432   $ echo "s =        [svn]       $SVNREPO/src" >> .hgsub
   430   $ echo "s =        [svn]       $SVNREPO/src" >> .hgsub
   433   $ hg add .hgsub
   431   $ hg add .hgsub
   434   $ hg ci -m addsub
   432   $ hg ci -m addsub
   435   committing subrepository s
       
   436   $ echo a > a
   433   $ echo a > a
   437   $ hg ci -Am adda
   434   $ hg ci -Am adda
   438   adding a
   435   adding a
   439   $ hg up 0
   436   $ hg up 0
   440   0 files updated, 0 files merged, 1 files removed, 0 files unresolved
   437   0 files updated, 0 files merged, 1 files removed, 0 files unresolved
   441   $ svn up -qr6 s
   438   $ svn up -qr6 s
   442   $ hg ci -m updatesub
   439   $ hg ci -m updatesub
   443   committing subrepository s
       
   444   created new head
   440   created new head
   445   $ echo pyc > s/dir/epsilon.pyc
   441   $ echo pyc > s/dir/epsilon.pyc
   446   $ hg up 1
   442   $ hg up 1
   447   D    *s/dir (glob)
   443   D    *s/dir (glob)
   448   
   444   
   460   $ hg checkout tip
   456   $ hg checkout tip
   461   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
   457   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
   462   $ echo "obstruct =        [svn]       $SVNREPO/externals" >> .hgsub
   458   $ echo "obstruct =        [svn]       $SVNREPO/externals" >> .hgsub
   463   $ svn co -r5 --quiet "$SVNREPO"/externals obstruct
   459   $ svn co -r5 --quiet "$SVNREPO"/externals obstruct
   464   $ hg commit -m 'Start making obstructed working copy'
   460   $ hg commit -m 'Start making obstructed working copy'
   465   committing subrepository obstruct
       
   466   $ hg book other
   461   $ hg book other
   467   $ hg co -r 'p1(tip)'
   462   $ hg co -r 'p1(tip)'
   468   2 files updated, 0 files merged, 0 files removed, 0 files unresolved
   463   2 files updated, 0 files merged, 0 files removed, 0 files unresolved
   469   $ echo "obstruct =        [svn]       $SVNREPO/src" >> .hgsub
   464   $ echo "obstruct =        [svn]       $SVNREPO/src" >> .hgsub
   470   $ svn co -r5 --quiet "$SVNREPO"/src obstruct
   465   $ svn co -r5 --quiet "$SVNREPO"/src obstruct
   471   $ hg commit -m 'Other branch which will be obstructed'
   466   $ hg commit -m 'Other branch which will be obstructed'
   472   committing subrepository obstruct
       
   473   created new head
   467   created new head
   474 
   468 
   475 Switching back to the head where we have another path mapped to the
   469 Switching back to the head where we have another path mapped to the
   476 same subrepo should work if the subrepo is clean.
   470 same subrepo should work if the subrepo is clean.
   477   $ hg co other
   471   $ hg co other
   528   $ svn co "$SVNREPO/branch"@10 recreated
   522   $ svn co "$SVNREPO/branch"@10 recreated
   529   A    recreated/somethingold
   523   A    recreated/somethingold
   530   Checked out revision 10.
   524   Checked out revision 10.
   531   $ echo "recreated =        [svn]       $SVNREPO/branch" >> .hgsub
   525   $ echo "recreated =        [svn]       $SVNREPO/branch" >> .hgsub
   532   $ hg ci -m addsub
   526   $ hg ci -m addsub
   533   committing subrepository recreated
       
   534   $ cd recreated
   527   $ cd recreated
   535   $ svn up -q
   528   $ svn up -q
   536   $ cd ..
   529   $ cd ..
   537   $ hg ci -m updatesub
   530   $ hg ci -m updatesub
   538   committing subrepository recreated
       
   539   $ hg up -r-2
   531   $ hg up -r-2
   540   D    *recreated/somethingnew (glob)
   532   D    *recreated/somethingnew (glob)
   541   A    *recreated/somethingold (glob)
   533   A    *recreated/somethingold (glob)
   542   Checked out revision 10.
   534   Checked out revision 10.
   543   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   535   1 files updated, 0 files merged, 0 files removed, 0 files unresolved