fix tests, experimental travis speedup
This commit is contained in:
parent
1c4f4c2494
commit
f265cff3a9
|
@ -1,4 +1,5 @@
|
||||||
language: python
|
language: python
|
||||||
|
sudo: false
|
||||||
python:
|
python:
|
||||||
- "2.7"
|
- "2.7"
|
||||||
# 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
|
||||||
|
|
|
@ -11,7 +11,7 @@ def test_load_scripts():
|
||||||
|
|
||||||
for f in scripts:
|
for f in scripts:
|
||||||
if "har_extractor" in f:
|
if "har_extractor" in f:
|
||||||
f += " foo"
|
f += " -"
|
||||||
if "iframe_injector" in f:
|
if "iframe_injector" in f:
|
||||||
f += " foo" # one argument required
|
f += " foo" # one argument required
|
||||||
if "modify_response_body" in f:
|
if "modify_response_body" in f:
|
||||||
|
|
|
@ -274,7 +274,9 @@ class TestFlow:
|
||||||
f2 = f.copy()
|
f2 = f.copy()
|
||||||
a = f.get_state()
|
a = f.get_state()
|
||||||
b = f2.get_state()
|
b = f2.get_state()
|
||||||
assert f.get_state() == f2.get_state()
|
del a["id"]
|
||||||
|
del b["id"]
|
||||||
|
assert a == b
|
||||||
assert not f == f2
|
assert not f == f2
|
||||||
assert not f is f2
|
assert not f is f2
|
||||||
assert f.request.get_state() == f2.request.get_state()
|
assert f.request.get_state() == f2.request.get_state()
|
||||||
|
@ -333,6 +335,7 @@ class TestFlow:
|
||||||
assert f.get_state() == protocol.http.HTTPFlow.from_state(state).get_state()
|
assert f.get_state() == protocol.http.HTTPFlow.from_state(state).get_state()
|
||||||
|
|
||||||
f2 = f.copy()
|
f2 = f.copy()
|
||||||
|
f2.id = f.id # copy creates a different uuid
|
||||||
assert f.get_state() == f2.get_state()
|
assert f.get_state() == f2.get_state()
|
||||||
assert not f == f2
|
assert not f == f2
|
||||||
f2.error = Error("e2")
|
f2.error = Error("e2")
|
||||||
|
|
Loading…
Reference in New Issue