~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to testweave.py

  • Committer: Martin Pool
  • Date: 2005-06-28 09:27:28 UTC
  • mto: This revision was merged to the branch mainline in revision 852.
  • Revision ID: mbp@sourcefrog.net-20050628092728-6b8da9d04400bcc2
Add another constraint: revisions should not delete text that they
just inserted

Show diffs side-by-side

added added

removed removed

Lines of Context:
161
161
 
162
162
 
163
163
 
 
164
class SuicideDelete(TestBase):
 
165
    def runTest(self):
 
166
        k = Weave()
 
167
 
 
168
        k._v = [VerInfo([]),
 
169
                ]
 
170
        k._l = [('{', 0),
 
171
                'first line',
 
172
                ('[', 0),
 
173
                'deleted in 0',
 
174
                (']', 0),
 
175
                ('}', 0),
 
176
                ]
 
177
 
 
178
        self.assertRaises(WeaveFormatError,
 
179
                          k.get,
 
180
                          0)        
 
181
 
 
182
 
 
183
 
164
184
class CannedDelete(TestBase):
165
185
    """Unpack canned weave with deleted lines."""
166
186
    def runTest(self):