Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mhils committed Nov 15, 2014
1 parent a699bdc commit 667fe0c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@
'examples': [
"pytz",
"harparser",
"beautifulsoup4"
]
}
)
4 changes: 2 additions & 2 deletions test/test_examples.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
import glob
import mock
from libmproxy import utils, script
from libmproxy.proxy import config
import tservers

@mock.patch.dict("sys.modules", {"bs4": mock.Mock()})
def test_load_scripts():
example_dir = utils.Data("libmproxy").path("../examples")
scripts = glob.glob("%s/*.py" % example_dir)

tmaster = tservers.TestMaster(config.ProxyConfig())

for f in scripts:
if "har_extractor" in f:
f += " foo"
if "iframe_injector" in f:
f += " foo" # one argument required
if "modify_response_body" in f:
Expand Down

0 comments on commit 667fe0c

Please sign in to comment.