~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

MergeĀ inĀ upstream.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
                          TestSuite,
30
30
                          TestLoader,
31
31
                          )
 
32
import bzrlib.ui as ui
 
33
 
32
34
 
33
35
def test_suite():
34
36
    testmod_names = [
38
40
                     'bzrlib.tests.blackbox.test_cat',
39
41
                     'bzrlib.tests.blackbox.test_checkout',
40
42
                     'bzrlib.tests.blackbox.test_commit',
 
43
                     'bzrlib.tests.blackbox.test_conflicts',
41
44
                     'bzrlib.tests.blackbox.test_diff',
42
45
                     'bzrlib.tests.blackbox.test_export',
43
46
                     'bzrlib.tests.blackbox.test_find_merge_base',
48
51
                     'bzrlib.tests.blackbox.test_missing',
49
52
                     'bzrlib.tests.blackbox.test_outside_wt',
50
53
                     'bzrlib.tests.blackbox.test_pull',
 
54
                     'bzrlib.tests.blackbox.test_reconcile',
51
55
                     'bzrlib.tests.blackbox.test_re_sign',
52
56
                     'bzrlib.tests.blackbox.test_revert',
53
57
                     'bzrlib.tests.blackbox.test_revno',
78
82
            return self.run_bzr_captured(args, retcode=retcode)[0]
79
83
        else:
80
84
            return self.run_bzr_captured(args, retcode=retcode)
 
85
 
 
86
 
 
87
class TestUIFactory(ui.UIFactory):
 
88
    """A UI Factory for testing - hide the progress bar but emit note()s."""
 
89
 
 
90
    def clear(self):
 
91
        """See progress.ProgressBar.clear()."""
 
92
 
 
93
    def note(self, fmt_string, *args, **kwargs):
 
94
        """See progress.ProgressBar.note()."""
 
95
        print fmt_string % args
 
96
 
 
97
    def progress_bar(self):
 
98
        return self
 
99
        
 
100
    def update(self, message, count=None, total=None):
 
101
        """See progress.ProgressBar.update()."""