~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/testdiff.py

  • Committer: Aaron Bentley
  • Date: 2005-08-10 17:39:16 UTC
  • mto: (1092.1.41) (1185.3.4) (974.1.47)
  • mto: This revision was merged to the branch mainline in revision 1110.
  • Revision ID: abentley@panoramicfeedback.com-20050810173916-77580019d21a0e82
Removed MergeTree.inventory

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
from bzrlib.selftest import TestCase
 
1
from bzrlib.selftest import TestBase
2
2
from bzrlib.diff import internal_diff
3
3
from cStringIO import StringIO
4
4
def udiff_lines(old, new):
21
21
    assert '@@' in lines[2][2:], \
22
22
        "Unterminated hunk header for patch:\n%s" % "".join(lines)
23
23
 
24
 
class AddNL(TestCase):
 
24
class AddNL(TestBase):
25
25
    """
26
26
    diff generates a valid diff for patches that add a newline
27
27
    """
32
32
            "expected no-nl, got %r" % lines[4]
33
33
 
34
34
 
35
 
class AddNL2(TestCase):
 
35
class AddNL2(TestBase):
36
36
    """
37
37
    diff generates a valid diff for patches that change last line and add a
38
38
    newline
43
43
        assert lines[4] == '\\ No newline at end of file\n', \
44
44
            "expected no-nl, got %r" % lines[4]
45
45
 
46
 
class RemoveNL(TestCase):
 
46
class RemoveNL(TestBase):
47
47
    """
48
48
    diff generates a valid diff for patches that change last line and add a
49
49
    newline