From 667fe0c20b43e2c5af5380591015b122da79b013 Mon Sep 17 00:00:00 2001 From: Maximilian Hils Date: Sat, 15 Nov 2014 23:10:25 +0100 Subject: [PATCH] fix tests --- setup.py | 1 + test/test_examples.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 1d3c62051..79398a186 100644 --- a/setup.py +++ b/setup.py @@ -84,6 +84,7 @@ setup( 'examples': [ "pytz", "harparser", + "beautifulsoup4" ] } ) diff --git a/test/test_examples.py b/test/test_examples.py index fd42e6f08..a5a212cd1 100644 --- a/test/test_examples.py +++ b/test/test_examples.py @@ -1,10 +1,8 @@ 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) @@ -12,6 +10,8 @@ def test_load_scripts(): 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: