~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/bundle/__init__.py

Workaround SSLFile wrong readline prototype and fix bogus tests.

* bzrlib/tests/test_read_bundle.py:
(load_tests): Not all tests are parametrized.
(TestDeprecations): Deprecate read_bundle_from_url.
(TestReadBundleFromURL.test_read_mergeable_from_url): Test
read_mergeable_from_url instead of read_bundle_from_url which has
no possible_transports parameter and is deprecated.
(TestReadBundleFromURL.test_read_mergeable_respects_possible_transports):
Fix the test so that it respects the transport class it's supposed
to use.

* bzrlib/transport/http/_urllib2_wrappers.py:
(_ReportingFileSocket.readline): Workaround bug in httplib for
python-2.4 and 2.5.

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
# along with this program; if not, write to the Free Software
15
15
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
16
16
 
 
17
from bzrlib.symbol_versioning import deprecated_function, deprecated_in
17
18
from bzrlib.lazy_import import lazy_import
18
19
lazy_import(globals(), """
19
20
from bzrlib import (
29
30
from bzrlib.trace import note
30
31
 
31
32
 
 
33
@deprecated_function(deprecated_in((1, 12, 0)))
32
34
def read_bundle_from_url(url):
33
35
    return read_mergeable_from_url(url, _do_directive=False)
34
36