~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_diff.py

  • Committer: Martin Pool
  • Date: 2010-07-21 09:58:42 UTC
  • mfrom: (4797.58.7 2.1)
  • mto: (5050.3.13 2.2)
  • mto: This revision was merged to the branch mainline in revision 5365.
  • Revision ID: mbp@canonical.com-20100721095842-hz0obu8gl0x05nty
merge up 2.1 to 2.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
    DiffTree,
30
30
    format_registry as diff_format_registry,
31
31
    )
32
 
from bzrlib.tests import (
33
 
    features,
34
 
    )
35
32
 
36
33
 
37
34
def subst_dates(string):
324
321
        output = self.run_bzr('diff --format=boo', retcode=1)
325
322
        self.assertTrue("BOO!" in output[0])
326
323
 
 
324
 
327
325
class TestCheckoutDiff(TestDiff):
328
326
 
329
327
    def make_example_branch(self):
402
400
        self.assertEndsWith(out, "\n@@ -0,0 +1 @@\n"
403
401
                                 "+baz\n\n")
404
402
 
405
 
    def test_external_diff_options_and_using(self):
406
 
        """Test that the options are passed correctly to an external diff process"""
407
 
        self.requireFeature(features.diff_feature)
408
 
        self.make_example_branch()
409
 
        self.build_tree_contents([('hello', 'Foo\n')])
410
 
        out, err = self.run_bzr('diff --diff-options -i --using diff',
411
 
                                    retcode=1)
412
 
        self.assertEquals("=== modified file 'hello'\n", out)
413
 
        self.assertEquals('', err)
414
 
 
415
403
 
416
404
class TestDiffOutput(DiffBase):
417
405