~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_tuned_gzip.py

  • Committer: Robert Collins
  • Date: 2007-03-08 04:06:06 UTC
  • mfrom: (2323.1.1 integration)
  • mto: This revision was merged to the branch mainline in revision 2442.
  • Revision ID: robertc@robertcollins.net-20070308040606-84gsniv56huiyjt4
Merge bzr.dev.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2006 by Canonical Ltd
 
1
# Copyright (C) 2006 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
25
25
import zlib
26
26
 
27
27
 
28
 
from bzrlib.tuned_gzip import *
 
28
from bzrlib import tuned_gzip
29
29
 
30
30
 
31
31
class FakeDecompress(object):
74
74
        # read more bytes if there is less than 8 bytes (the 
75
75
        # gzip trailer) unread.
76
76
        stream = StringIO('\0\0\0\0\0\0\0\0')
77
 
        myfile = GzipFile(fileobj=stream)
 
77
        myfile = tuned_gzip.GzipFile(fileobj=stream)
78
78
        # disable the _new_member check, we are microtesting.
79
79
        myfile._new_member = False
80
80
        myfile.crc = zlib.crc32('')