mitmproxy/test/test_examples.py
Maximilian Hils a17a53269d fix #253
2014-05-15 14:37:05 +02:00

12 lines
330 B
Python

from libmproxy import utils, script
import glob
from libmproxy.proxy import config
import tservers
example_dir = utils.Data("libmproxy").path("../examples/")
scripts = glob.glob("%s*.py" % example_dir)
tmaster = tservers.TestMaster(config.ProxyConfig())
for f in scripts:
script.Script(f, tmaster) # Loads the script file.