/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 breezy/tests/test_shelf_ui.py

  • Committer: Jelmer Vernooij
  • Date: 2017-05-22 00:56:52 UTC
  • mfrom: (6621.2.26 py3_pokes)
  • Revision ID: jelmer@jelmer.uk-20170522005652-yjahcr9hwmjkno7n
Merge Python3 porting work ('py3 pokes')

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
16
16
 
17
17
 
18
 
from cStringIO import StringIO
19
18
import os
20
19
import sys
21
20
from textwrap import dedent
22
21
 
23
 
from breezy import (
 
22
from .. import (
24
23
    errors,
25
24
    shelf_ui,
26
25
    revision,
27
26
    tests,
28
 
)
29
 
from breezy.tests import script
30
 
from breezy.tests import (
 
27
    )
 
28
from ..sixish import (
 
29
    BytesIO,
 
30
    )
 
31
from . import script
 
32
from . import (
31
33
    features,
32
34
    )
33
35
 
42
44
                                  auto, auto_apply, file_list, message,
43
45
                                  destroy, reporter=reporter)
44
46
        self.expected = []
45
 
        self.diff_writer = StringIO()
 
47
        self.diff_writer = BytesIO()
46
48
 
47
49
    def expect(self, message, response):
48
50
        self.expected.append((message, response))
512
514
 
513
515
    def test_unshelve_args_preview(self):
514
516
        tree = self.create_tree_with_shelf()
515
 
        write_diff_to = StringIO()
 
517
        write_diff_to = BytesIO()
516
518
        unshelver = shelf_ui.Unshelver.from_args(
517
519
            directory='tree', action='preview', write_diff_to=write_diff_to)
518
520
        try: