tests/test-import.t
branchstable
changeset 16124 0e0060bf2f44
parent 16123 b0c7525f826d
child 16650 fcb97d9a26cd
equal deleted inserted replaced
16123:b0c7525f826d 16124:0e0060bf2f44
   443   $ hg ci -m brancha
   443   $ hg ci -m brancha
   444   created new head
   444   created new head
   445   $ hg import --no-commit -v fuzzy-tip.patch
   445   $ hg import --no-commit -v fuzzy-tip.patch
   446   applying fuzzy-tip.patch
   446   applying fuzzy-tip.patch
   447   patching file a
   447   patching file a
   448   Hunk #1 succeeded at 1 with fuzz 2 (offset -2 lines).
   448   Hunk #1 succeeded at 2 with fuzz 1 (offset 0 lines).
   449   applied to working directory
   449   applied to working directory
   450   $ hg revert -a
   450   $ hg revert -a
   451   reverting a
   451   reverting a
   452 
   452 
   453 
   453 
   460 test fuzziness with eol=auto
   460 test fuzziness with eol=auto
   461 
   461 
   462   $ hg --config patch.eol=auto import --no-commit -v fuzzy-tip.patch
   462   $ hg --config patch.eol=auto import --no-commit -v fuzzy-tip.patch
   463   applying fuzzy-tip.patch
   463   applying fuzzy-tip.patch
   464   patching file a
   464   patching file a
   465   Hunk #1 succeeded at 1 with fuzz 2 (offset -2 lines).
   465   Hunk #1 succeeded at 2 with fuzz 1 (offset 0 lines).
   466   applied to working directory
   466   applied to working directory
   467   $ cd ..
   467   $ cd ..
   468 
   468 
   469 
   469 
   470 Test hunk touching empty files (issue906)
   470 Test hunk touching empty files (issue906)
  1027   > +++ b/a
  1027   > +++ b/a
  1028   > @@ -10,0 +10,1 @@
  1028   > @@ -10,0 +10,1 @@
  1029   > +line
  1029   > +line
  1030   > EOF
  1030   > EOF
  1031 
  1031 
       
  1032   $ cat > 04-middle-of-file-completely-fuzzed.diff <<EOF
       
  1033   > diff --git a/a b/a
       
  1034   > --- a/a
       
  1035   > +++ b/a
       
  1036   > @@ -1,1 +1,1 @@
       
  1037   > -2
       
  1038   > +add some skew
       
  1039   > @@ -2,2 +2,3 @@
       
  1040   >  not matching, should fuzz
       
  1041   >  ... a bit
       
  1042   > +line
       
  1043   > EOF
       
  1044 
  1032   $ cat > a <<EOF
  1045   $ cat > a <<EOF
  1033   > 1
  1046   > 1
  1034   > 2
  1047   > 2
  1035   > 3
  1048   > 3
  1036   > 4
  1049   > 4
  1069   1
  1082   1
  1070   2
  1083   2
  1071   3
  1084   3
  1072   4
  1085   4
  1073   line
  1086   line
  1074 
  1087   applying 04-middle-of-file-completely-fuzzed.diff
       
  1088   patching file a
       
  1089   Hunk #1 succeeded at 2 (offset 1 lines).
       
  1090   Hunk #2 succeeded at 5 with fuzz 2 (offset 1 lines).
       
  1091   applied to working directory
       
  1092   1
       
  1093   add some skew
       
  1094   3
       
  1095   4
       
  1096   line
       
  1097