From 0af35018fbdf2460d8890a7d7b4ad8246a3d121d 2013-12-03 21:47:08 From: Thomas Kluyver Date: 2013-12-03 21:47:08 Subject: [PATCH] Allow any options to be passed through test function --- diff --git a/IPython/testing/__init__.py b/IPython/testing/__init__.py index e56516c..d36a38b 100644 --- a/IPython/testing/__init__.py +++ b/IPython/testing/__init__.py @@ -13,17 +13,18 @@ #----------------------------------------------------------------------------- # User-level entry point for testing -def test(all=False): +def test(**kwargs): """Run the entire IPython test suite. - For fine-grained control, you should use the :file:`iptest` script supplied - with the IPython installation.""" + Any of the options for run_iptestall() may be passed as keyword arguments. + """ # Do the import internally, so that this function doesn't increase total # import time from .iptestcontroller import run_iptestall, default_options options = default_options() - options.all = all + for name, val in kwargs.items(): + setattr(options, name, val) run_iptestall(options) # So nose doesn't try to run this as a test itself and we end up with an