~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_bundle.py

  • Committer: John Arbash Meinel
  • Date: 2009-07-24 18:26:21 UTC
  • mfrom: (4567 +trunk)
  • mto: This revision was merged to the branch mainline in revision 4568.
  • Revision ID: john@arbash-meinel.com-20090724182621-68s2jhoqf3pn72n7
Merge bzr.dev 4567 to resolve NEWS

Show diffs side-by-side

added added

removed removed

Lines of Context:
1612
1612
        self.assertRaises(errors.NotABundle, read_mergeable_from_url,
1613
1613
                          'foo:bar')
1614
1614
 
 
1615
    def test_infinite_redirects_are_not_a_bundle(self):
 
1616
        """If a URL causes TooManyRedirections then NotABundle is raised.
 
1617
        """
 
1618
        from bzrlib.tests.blackbox.test_push import RedirectingMemoryServer
 
1619
        server = RedirectingMemoryServer()
 
1620
        server.setUp()
 
1621
        url = server.get_url() + 'infinite-loop'
 
1622
        self.addCleanup(server.tearDown)
 
1623
        self.assertRaises(errors.NotABundle, read_mergeable_from_url, url)
 
1624
 
1615
1625
    def test_smart_server_connection_reset(self):
1616
1626
        """If a smart server connection fails during the attempt to read a
1617
1627
        bundle, then the ConnectionReset error should be propagated.