/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/workingtree_implementations/test_parents.py

merge bzr.dev r4164

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
    osutils,
25
25
    revision as _mod_revision,
26
26
    symbol_versioning,
 
27
    tests,
27
28
    )
28
29
from bzrlib.inventory import (
29
30
    Inventory,
32
33
    InventoryLink,
33
34
    )
34
35
from bzrlib.revision import Revision
35
 
from bzrlib.tests import (
36
 
    KnownFailure,
37
 
    SymlinkFeature,
38
 
    TestNotApplicable,
39
 
    UnicodeFilenameFeature,
40
 
    )
41
36
from bzrlib.tests.workingtree_implementations import TestCaseWithWorkingTree
42
37
from bzrlib.uncommit import uncommit
43
38
 
234
229
 
235
230
    def test_unicode_symlink(self):
236
231
        # this tests bug #272444
237
 
        self.requireFeature(SymlinkFeature)
238
 
        self.requireFeature(UnicodeFilenameFeature)
 
232
        self.requireFeature(tests.SymlinkFeature)
 
233
        self.requireFeature(tests.UnicodeFilenameFeature)
239
234
 
240
235
        tree = self.make_branch_and_tree('tree1')
241
236
 
245
240
        os.symlink(u'\u03a9','tree1/link_name')
246
241
        tree.add(['link_name'],['link-id'])
247
242
 
248
 
        try:
249
 
            # the actual commit occurs without errors (strangely):
250
 
            revision1 = tree.commit('added a link to a Unicode target')
251
 
            # python 2.4 failed with UnicodeDecodeError on this commit:
252
 
            revision2 = tree.commit('this revision will be discarded')
253
 
            # python 2.5 failed with UnicodeEncodeError on set_parent_ids:
254
 
            tree.set_parent_ids([revision1])
255
 
        except (UnicodeEncodeError, UnicodeDecodeError):
256
 
            raise KnownFailure('there is no support for'
257
 
                               ' symlinks to non-ASCII targets (bug #272444)')
 
243
        revision1 = tree.commit('added a link to a Unicode target')
 
244
        revision2 = tree.commit('this revision will be discarded')
 
245
        tree.set_parent_ids([revision1])
258
246
 
259
247
 
260
248
class TestAddParent(TestParents):