aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/ipython/py2/IPython/testing/__init__.py
diff options
context:
space:
mode:
authorDevtools Arcadia <arcadia-devtools@yandex-team.ru>2022-02-07 18:08:42 +0300
committerDevtools Arcadia <arcadia-devtools@mous.vla.yp-c.yandex.net>2022-02-07 18:08:42 +0300
commit1110808a9d39d4b808aef724c861a2e1a38d2a69 (patch)
treee26c9fed0de5d9873cce7e00bc214573dc2195b7 /contrib/python/ipython/py2/IPython/testing/__init__.py
downloadydb-1110808a9d39d4b808aef724c861a2e1a38d2a69.tar.gz
intermediate changes
ref:cde9a383711a11544ce7e107a78147fb96cc4029
Diffstat (limited to 'contrib/python/ipython/py2/IPython/testing/__init__.py')
-rw-r--r--contrib/python/ipython/py2/IPython/testing/__init__.py38
1 files changed, 38 insertions, 0 deletions
diff --git a/contrib/python/ipython/py2/IPython/testing/__init__.py b/contrib/python/ipython/py2/IPython/testing/__init__.py
new file mode 100644
index 0000000000..165f503169
--- /dev/null
+++ b/contrib/python/ipython/py2/IPython/testing/__init__.py
@@ -0,0 +1,38 @@
+"""Testing support (tools to test IPython itself).
+"""
+
+#-----------------------------------------------------------------------------
+# Copyright (C) 2009-2011 The IPython Development Team
+#
+# Distributed under the terms of the BSD License. The full license is in
+# the file COPYING, distributed as part of this software.
+#-----------------------------------------------------------------------------
+
+#-----------------------------------------------------------------------------
+# Functions
+#-----------------------------------------------------------------------------
+
+# User-level entry point for testing
+def test(**kwargs):
+ """Run the entire IPython test suite.
+
+ Any of the options for run_iptestall() may be passed as keyword arguments.
+
+ For example::
+
+ IPython.test(testgroups=['lib', 'config', 'utils'], fast=2)
+
+ will run those three sections of the test suite, using two processes.
+ """
+
+ # Do the import internally, so that this function doesn't increase total
+ # import time
+ from .iptestcontroller import run_iptestall, default_options
+ options = default_options()
+ 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
+# infinite test loop
+test.__test__ = False