]> granicus.if.org Git - python/commitdiff
Merge 3.3
authorDonald Stufft <donald@stufft.io>
Wed, 3 Aug 2016 22:48:17 +0000 (18:48 -0400)
committerDonald Stufft <donald@stufft.io>
Wed, 3 Aug 2016 22:48:17 +0000 (18:48 -0400)
1  2 
Lib/distutils/config.py
Lib/distutils/tests/test_upload.py

Simple merge
index bf4d558bf7d9cb935738584fecc5813ff65256f2,1402343e0a8ba63b53e1d103e90d1cf3c1a4db3b..cbbbe33bb064afd45a034097d89b67b8a97f72b8
@@@ -90,7 -86,7 +90,7 @@@ class uploadTestCase(PyPIRCCommandTestC
          cmd.finalize_options()
          for attr, waited in (('username', 'me'), ('password', 'secret'),
                               ('realm', 'pypi'),
-                              ('repository', 'https://upload.pypi.io/legacy/')):
 -                             ('repository', 'https://pypi.python.org/pypi')):
++                             ('repository', 'https://upload.pypi.org/legacy/')):
              self.assertEqual(getattr(cmd, attr), waited)
  
      def test_saved_password(self):
  
          # what did we send ?
          headers = dict(self.last_open.req.headers)
 -        self.assertEqual(headers['Content-length'], '2087')
 -        self.assertTrue(headers['Content-type'].startswith('multipart/form-data'))
 +        self.assertEqual(headers['Content-length'], '2161')
 +        content_type = headers['Content-type']
 +        self.assertTrue(content_type.startswith('multipart/form-data'))
          self.assertEqual(self.last_open.req.get_method(), 'POST')
-         expected_url = 'https://upload.pypi.io/legacy/'
 -        self.assertEqual(self.last_open.req.get_full_url(),
 -                         'https://upload.pypi.org/legacy/')
 -        self.assertIn(b'xxx', self.last_open.req.data)
++        expected_url = 'https://upload.pypi.org/legacy/'
 +        self.assertEqual(self.last_open.req.get_full_url(), expected_url)
 +        self.assertTrue(b'xxx' in self.last_open.req.data)
  
          # The PyPI response body was echoed
          results = self.get_logs(INFO)