~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

  • Committer: Patch Queue Manager
  • Date: 2012-03-06 19:49:19 UTC
  • mfrom: (6472.2.6 use-bzr-controldir)
  • Revision ID: pqm@pqm.ubuntu.com-20120306194919-kt7mj6xmhifsgees
(jelmer) Use bzrlib.controldir for generic access to control directories,
 rather than bzrlib.bzrdir. (Jelmer Vernooij)

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 
21
21
import os
22
22
 
23
 
from bzrlib.bzrdir import BzrDir
 
23
from bzrlib.controldir import ControlDir
24
24
from bzrlib import (
25
 
        osutils,
26
 
        urlutils,
27
 
        branch,
28
 
        )
 
25
    osutils,
 
26
    urlutils,
 
27
    branch,
 
28
    )
29
29
from bzrlib.workingtree import WorkingTree
30
30
from bzrlib.tests import (
31
 
        TestCaseWithTransport,
32
 
        script,
33
 
        )
 
31
    TestCaseWithTransport,
 
32
    script,
 
33
    )
34
34
from bzrlib.tests.features import UnicodeFilenameFeature
35
35
from bzrlib.directory_service import directories
36
36
 
237
237
        tree.add('file-1')
238
238
        revid1 = tree.commit('rev1')
239
239
        self.run_bzr(['switch', '-b', 'anotherbranch'], working_dir='branch-1')
240
 
        bzrdir = BzrDir.open("branch-1")
 
240
        bzrdir = ControlDir.open("branch-1")
241
241
        self.assertEquals(
242
242
            set([b.name for b in bzrdir.list_branches()]),
243
243
            set(["foo", "anotherbranch"]))
256
256
        tree.add('file-1')
257
257
        revid1 = tree.commit('rev1')
258
258
        self.run_bzr(['switch', '-b', u'branch\xe9'], working_dir='branch-1')
259
 
        bzrdir = BzrDir.open("branch-1")
 
259
        bzrdir = ControlDir.open("branch-1")
260
260
        self.assertEquals(
261
261
            set([b.name for b in bzrdir.list_branches()]),
262
262
            set(["foo", u"branch\xe9"]))