tests/test-subrepo-git.t
changeset 24778 a48b65ab428d
parent 24581 85219d6ece67
child 24902 986a5c23b1c1
equal deleted inserted replaced
24777:077683371b7b 24778:a48b65ab428d
   783   $ hg diff --subrepos --stat
   783   $ hg diff --subrepos --stat
   784   \s*barfoo |\s*1 + (re)
   784   \s*barfoo |\s*1 + (re)
   785   \s*foobar |\s*2 +- (re)
   785   \s*foobar |\s*2 +- (re)
   786    2 files changed, 2 insertions\(\+\), 1 deletions?\(-\) (re)
   786    2 files changed, 2 insertions\(\+\), 1 deletions?\(-\) (re)
   787 
   787 
   788 ensure adding include/exclude ignores the subrepo
   788 adding an include should ignore the other elements
   789   $ hg diff --subrepos -I s/foobar
   789   $ hg diff --subrepos -I s/foobar
       
   790   diff --git a/s/foobar b/s/foobar
       
   791   index 8a5a5e2..bd5812a 100644
       
   792   --- a/s/foobar
       
   793   +++ b/s/foobar
       
   794   @@ -1,4 +1,4 @@
       
   795   -woopwoop
       
   796   +woop    woop
       
   797    
       
   798    foo
       
   799    bar
       
   800 
       
   801 adding an exclude should ignore this element
   790   $ hg diff --subrepos -X s/foobar
   802   $ hg diff --subrepos -X s/foobar
       
   803   diff --git a/s/barfoo b/s/barfoo
       
   804   new file mode 100644
       
   805   index 0000000..257cc56
       
   806   --- /dev/null
       
   807   +++ b/s/barfoo
       
   808   @@ -0,0 +1 @@
       
   809   +foo
       
   810 
       
   811 moving a file should show a removal and an add
       
   812   $ hg revert --all
       
   813   reverting subrepo ../gitroot
       
   814   $ cd s
       
   815   $ git mv foobar woop
       
   816   $ cd ..
       
   817   $ hg diff --subrepos
       
   818   diff --git a/s/foobar b/s/foobar
       
   819   deleted file mode 100644
       
   820   index 8a5a5e2..0000000
       
   821   --- a/s/foobar
       
   822   +++ /dev/null
       
   823   @@ -1,4 +0,0 @@
       
   824   -woopwoop
       
   825   -
       
   826   -foo
       
   827   -bar
       
   828   diff --git a/s/woop b/s/woop
       
   829   new file mode 100644
       
   830   index 0000000..8a5a5e2
       
   831   --- /dev/null
       
   832   +++ b/s/woop
       
   833   @@ -0,0 +1,4 @@
       
   834   +woopwoop
       
   835   +
       
   836   +foo
       
   837   +bar
       
   838   $ rm s/woop
   791 
   839 
   792 revert the subrepository
   840 revert the subrepository
   793   $ hg revert --all
   841   $ hg revert --all
   794   reverting subrepo ../gitroot
   842   reverting subrepo ../gitroot
   795 
   843