~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

  • Committer: Alexander Belchenko
  • Date: 2006-12-13 08:15:54 UTC
  • mto: This revision was merged to the branch mainline in revision 2204.
  • Revision ID: bialix@ukr.net-20061213081554-hglev5j0rzv0xhon
Provide tests to illustrate bug #55276 on win32.

Change blackbox tests for cat and bundle commands
to use run_bzr_subprocess and therefore grab
real output (windows mangle line-endings LF -> CRLF).
Also provide new blackbox tests for diff command.

To check that tests failed you need to run on win32:

python bzr selftest blackbox.test_cat
python bzr selftest blackbox.test_bundle
python bzr selftest blackbox.test_diff

Show diffs side-by-side

added added

removed removed

Lines of Context:
82
82
        bi = read_bundle(StringIO(self.run_bzr('bundle', '-r', '-2..-1')[0]))
83
83
        self.assertRevisions(bi, ['revision3'])
84
84
        self.run_bzr('bundle', '../grandparent', '-r', '-2..-1', retcode=3)
 
85
 
 
86
    def test_output(self):
 
87
        # check output for consistency
 
88
        # win32 stdout convert LF to CRLF and this is break created bundle
 
89
        self.make_trees()        
 
90
        os.chdir('branch')
 
91
        stdout = self.run_bzr_subprocess('bundle')[0]
 
92
        br = read_bundle(StringIO(stdout))
 
93
        self.assertRevisions(br, ['revision3'])