~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_ui.py

  • Committer: Martin Pool
  • Date: 2009-03-12 07:13:53 UTC
  • mto: This revision was merged to the branch mainline in revision 4144.
  • Revision ID: mbp@sourcefrog.net-20090312071353-usd2dh37dsriuses
Progress bars always repaint when task structure is changed

Show diffs side-by-side

added added

removed removed

Lines of Context:
288
288
        # so we're in the first half of the main task, and half way through
289
289
        # that
290
290
        self.assertEqual(
291
 
'[####-               ] reticulating splines:stage2 1/2'
 
291
r'[####\               ] reticulating splines:stage2 1/2'
292
292
            , uif._progress_view._render_line())
293
293
        # if the nested task is complete, then we're all the way through the
294
294
        # first half of the overall work
295
295
        task2.update('stage2', 2, 2)
296
296
        self.assertEqual(
297
 
r'[#########\          ] reticulating splines:stage2 2/2'
 
297
r'[#########|          ] reticulating splines:stage2 2/2'
298
298
            , uif._progress_view._render_line())
299
299
 
300
300
    def test_render_progress_sub_nested(self):
310
310
        # progress indication, just a label; and the bottom one is half done,
311
311
        # so the overall fraction is 1/4
312
312
        self.assertEqual(
313
 
            r'[####-               ] a:b:c 1/2'
 
313
            r'[####|               ] a:b:c 1/2'
314
314
            , uif._progress_view._render_line())
315
315