scrapinghub/splash — pull request #66 by andresp99999 (2014-01-11 16:31:45+00:00)
Title: Fix proxy tests

I rebuilt my splash test VM and when running the tests I ran into a couple of issues with the proxy tests:

* test_proxy_server uses simplejson but the lib was missing from the requirements.
* When running the proxy tests I got the exception shown below. It seems that a recent update to request added the need for explicit schemes in the proxy URLs.

```
Traceback (most recent call last):
File "/opt/splash/splash/tests/test_render.py", line 439, in test_simple_js
r = self._runjs_request(js_source).json()
File "/opt/splash/splash/tests/test_proxy_server.py", line 89, in _runjs_request
return self.request(query, render_format=render_format)
File "/opt/splash/splash/tests/test_render.py", line 74, in request
return self._get_handler().request(query, render_format)
File "/opt/splash/splash/tests/test_proxy_server.py", line 40, in request
return requests.get(url, headers=headers, proxies=self.proxies)
File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 55, in get
return request('get', url, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 44, in request
return session.request(method=method, url=url, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 383, in request
resp = self.send(prep, **send_kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 486, in send
r = adapter.send(request, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 309, in send
conn = self.get_connection(request.url, proxies)
File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 206, in get_connection
except_on_missing_scheme(proxy)
File "/usr/local/lib/python2.7/dist-packages/requests/utils.py", line 631, in except_on_missing_scheme
raise MissingSchema('Proxy URLs must have explicit schemes.')
MissingSchema: Proxy URLs must have explicit schemes.
```

This PR fixes both issues.