~alecu/ubuntu-sso-client/fix-997326

« back to all changes in this revision

Viewing changes to ubuntu_sso/utils/webclient/tests/test_qtnetwork.py

  • Committer: Tarmac
  • Author(s): Brian Curtin
  • Date: 2012-10-24 17:03:39 UTC
  • mfrom: (1007.2.2 sso-fix)
  • Revision ID: tarmac-20121024170339-o8llbtdplngqdtwt
- Only call QNetworkAccessManager.setProxy on Linux, as this method is broken on Windows.

Show diffs side-by-side

added added

removed removed

Lines of Context:
163
163
        """Test setting the proxy."""
164
164
        qtnetwork.WebClient()
165
165
        self.assertEqual(self.proxy, qtnetwork.WebClient.proxy_instance)
 
166
        # nam.setProxy does not work on Windows (PyQt 4.9.4)
 
167
        # so WebClient._set_proxy was changed to not call setProxy
 
168
        # like we do on Quantal.
 
169
        self.assertNotIn(('setProxy', self.proxy), self.called)
166
170
        self.assertIn(('systemProxyForQuery', self.query), self.called)
167
171
        self.assertIn(('setApplicationProxy', self.proxy), self.called)
168
172