fix tests, re-enable pypy, do housekeeping
This commit is contained in:
parent
17e44db9fd
commit
2ed09beae4
|
@ -2,7 +2,7 @@ language: python
|
||||||
sudo: false
|
sudo: false
|
||||||
python:
|
python:
|
||||||
- "2.7"
|
- "2.7"
|
||||||
# - pypy # pypy 2.5.0 has a regression bug which breaks our test suite.
|
- pypy
|
||||||
# command to install dependencies, e.g. pip install -r requirements.txt --use-mirrors
|
# command to install dependencies, e.g. pip install -r requirements.txt --use-mirrors
|
||||||
install:
|
install:
|
||||||
- "pip install --upgrade --src . -r requirements.txt"
|
- "pip install --upgrade --src . -r requirements.txt"
|
||||||
|
@ -20,4 +20,4 @@ notifications:
|
||||||
cache:
|
cache:
|
||||||
directories:
|
directories:
|
||||||
- /home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages
|
- /home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages
|
||||||
- /home/travis/virtualenv/pypy-2.4.0/site-packages
|
- /home/travis/virtualenv/pypy-2.5.0/site-packages
|
||||||
|
|
|
@ -309,10 +309,10 @@ class StickyCookieState:
|
||||||
# FIXME: We now know that Cookie.py screws up some cookies with
|
# FIXME: We now know that Cookie.py screws up some cookies with
|
||||||
# valid RFC 822/1123 datetime specifications for expiry. Sigh.
|
# valid RFC 822/1123 datetime specifications for expiry. Sigh.
|
||||||
c = Cookie.SimpleCookie(str(i))
|
c = Cookie.SimpleCookie(str(i))
|
||||||
m = c.values()[0]
|
for m in c.values():
|
||||||
k = self.ckey(m, f)
|
k = self.ckey(m, f)
|
||||||
if self.domain_match(f.request.host, k[0]):
|
if self.domain_match(f.request.host, k[0]):
|
||||||
self.jar[self.ckey(m, f)] = m
|
self.jar[k] = m
|
||||||
|
|
||||||
def handle_request(self, f):
|
def handle_request(self, f):
|
||||||
l = []
|
l = []
|
||||||
|
|
7
setup.py
7
setup.py
|
@ -33,8 +33,7 @@ script_deps = {
|
||||||
for script in scripts:
|
for script in scripts:
|
||||||
deps.update(script_deps[script])
|
deps.update(script_deps[script])
|
||||||
if os.name == "nt":
|
if os.name == "nt":
|
||||||
deps.add("pydivert>=0.0.4") # Transparent proxying on Windows
|
deps.add("pydivert>=0.0.7") # Transparent proxying on Windows
|
||||||
|
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="mitmproxy",
|
name="mitmproxy",
|
||||||
|
@ -55,6 +54,8 @@ setup(
|
||||||
"Programming Language :: Python",
|
"Programming Language :: Python",
|
||||||
"Programming Language :: Python :: 2",
|
"Programming Language :: Python :: 2",
|
||||||
"Programming Language :: Python :: 2.7",
|
"Programming Language :: Python :: 2.7",
|
||||||
|
"Programming Language :: Python :: Implementation :: CPython",
|
||||||
|
"Programming Language :: Python :: Implementation :: PyPy",
|
||||||
"Topic :: Security",
|
"Topic :: Security",
|
||||||
"Topic :: Internet",
|
"Topic :: Internet",
|
||||||
"Topic :: Internet :: WWW/HTTP",
|
"Topic :: Internet :: WWW/HTTP",
|
||||||
|
@ -63,7 +64,7 @@ setup(
|
||||||
],
|
],
|
||||||
packages=find_packages(),
|
packages=find_packages(),
|
||||||
include_package_data=True,
|
include_package_data=True,
|
||||||
scripts = scripts,
|
scripts=scripts,
|
||||||
install_requires=list(deps),
|
install_requires=list(deps),
|
||||||
extras_require={
|
extras_require={
|
||||||
'dev': [
|
'dev': [
|
||||||
|
|
|
@ -47,7 +47,7 @@ class TestStickyCookieState:
|
||||||
assert s.domain_match("google.com", ".google.com")
|
assert s.domain_match("google.com", ".google.com")
|
||||||
|
|
||||||
def test_handle_response(self):
|
def test_handle_response(self):
|
||||||
c = "SSID=mooo, FOO=bar; Domain=.google.com; Path=/; "\
|
c = "SSID=mooo; domain=.google.com, FOO=bar; Domain=.google.com; Path=/; "\
|
||||||
"Expires=Wed, 13-Jan-2021 22:23:01 GMT; Secure; "
|
"Expires=Wed, 13-Jan-2021 22:23:01 GMT; Secure; "
|
||||||
|
|
||||||
s, f = self._response(c, "host")
|
s, f = self._response(c, "host")
|
||||||
|
|
Loading…
Reference in New Issue