/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_revision.py

  • Committer: Vincent Ladeuil
  • Date: 2009-04-08 19:06:40 UTC
  • mto: (4276.1.1 integration)
  • mto: This revision was merged to the branch mainline in revision 4277.
  • Revision ID: v.ladeuil+lp@free.fr-20090408190640-ra8frcx4hj55qj02
Fix failure, add tests.

* bzrlib/tests/test_selftest.py:
(TestTestResult.test_startTests.InstrumentedTestResult): Check
that startTests is called once.
(TestRunSuite.test_runner_class): Check that
ExtendedTestResult.done() is called once.

* bzrlib/tests/blackbox/test_selftest.py:
(TestBenchmarkTests.test_benchmark_runs_benchmark_tests): Output
order has changed.

* bzrlib/tests/__init__.py:
(run_suite): At least subunit.TestProtocolClient doesn't define
done().

Show diffs side-by-side

added added

removed removed

Lines of Context:
208
208
        self.assertEqual('a', r.get_summary())
209
209
        r.message = '\na\nb'
210
210
        self.assertEqual('a', r.get_summary())
211
 
        r.message = None
212
 
        self.assertEqual('', r.get_summary())
213
211
 
214
212
    def test_get_apparent_author(self):
215
213
        r = revision.Revision('1')
229
227
                r.get_apparent_author)
230
228
        self.assertEqual('C', author)
231
229
 
232
 
    def test_get_apparent_author_none(self):
233
 
        r = revision.Revision('1')
234
 
        author = self.applyDeprecated(
235
 
                symbol_versioning.deprecated_in((1, 13, 0)),
236
 
                r.get_apparent_author)
237
 
        self.assertEqual(None, author)
238
 
 
239
230
    def test_get_apparent_authors(self):
240
231
        r = revision.Revision('1')
241
232
        r.committer = 'A'
245
236
        r.properties['authors'] = 'C\nD'
246
237
        self.assertEqual(['C', 'D'], r.get_apparent_authors())
247
238
 
248
 
    def test_get_apparent_authors_no_committer(self):
249
 
        r = revision.Revision('1')
250
 
        self.assertEqual([], r.get_apparent_authors())
251
 
 
252
239
 
253
240
class TestRevisionBugs(TestCase):
254
241
    """Tests for getting the bugs that a revision is linked to."""