/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_knit.py

  • Committer: Jelmer Vernooij
  • Date: 2017-05-21 18:10:28 UTC
  • mto: This revision was merged to the branch mainline in revision 6623.
  • Revision ID: jelmer@jelmer.uk-20170521181028-zn04pdfw0od9hfj3
Rename brzlib => breezy.

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
import gzip
21
21
import sys
22
22
 
23
 
from brzlib import (
 
23
from breezy import (
24
24
    errors,
25
25
    knit,
26
26
    multiparent,
29
29
    tests,
30
30
    transport,
31
31
    )
32
 
from brzlib.errors import (
 
32
from breezy.errors import (
33
33
    KnitHeaderError,
34
34
    NoSuchFile,
35
35
    )
36
 
from brzlib.index import *
37
 
from brzlib.knit import (
 
36
from breezy.index import *
 
37
from breezy.knit import (
38
38
    AnnotatedKnitContent,
39
39
    KnitContent,
40
40
    KnitVersionedFiles,
45
45
    _KnitKeyAccess,
46
46
    make_file_factory,
47
47
    )
48
 
from brzlib.patiencediff import PatienceSequenceMatcher
49
 
from brzlib.repofmt import (
 
48
from breezy.patiencediff import PatienceSequenceMatcher
 
49
from breezy.repofmt import (
50
50
    knitpack_repo,
51
51
    pack_repo,
52
52
    )
53
 
from brzlib.tests import (
 
53
from breezy.tests import (
54
54
    TestCase,
55
55
    TestCaseWithMemoryTransport,
56
56
    TestCaseWithTransport,
57
57
    TestNotApplicable,
58
58
    )
59
 
from brzlib.versionedfile import (
 
59
from breezy.versionedfile import (
60
60
    AbsentContentFactory,
61
61
    ConstantMapper,
62
62
    network_bytes_to_kind_and_offset,
63
63
    RecordingVersionedFilesDecorator,
64
64
    )
65
 
from brzlib.tests import (
 
65
from breezy.tests import (
66
66
    features,
67
67
    )
68
68
 
69
69
 
70
70
compiled_knit_feature = features.ModuleAvailableFeature(
71
 
    'brzlib._knit_load_data_pyx')
 
71
    'breezy._knit_load_data_pyx')
72
72
 
73
73
 
74
74
class KnitContentTestsMixin(object):
891
891
 
892
892
    def get_knit_index(self, transport, name, mode):
893
893
        mapper = ConstantMapper(name)
894
 
        from brzlib._knit_load_data_py import _load_data_py
 
894
        from breezy._knit_load_data_py import _load_data_py
895
895
        self.overrideAttr(knit, '_load_data', _load_data_py)
896
896
        allow_writes = lambda: 'w' in mode
897
897
        return _KndxIndex(transport, mapper, lambda:None, allow_writes, lambda:True)
1322
1322
 
1323
1323
    def get_knit_index(self, transport, name, mode):
1324
1324
        mapper = ConstantMapper(name)
1325
 
        from brzlib._knit_load_data_pyx import _load_data_c
 
1325
        from breezy._knit_load_data_pyx import _load_data_c
1326
1326
        self.overrideAttr(knit, '_load_data', _load_data_c)
1327
1327
        allow_writes = lambda: mode == 'w'
1328
1328
        return _KndxIndex(transport, mapper, lambda:None,