Python test.support.run_doctest() Examples
The following are 30
code examples of test.support.run_doctest().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
test.support
, or try the search function
.
Example #1
Source File: test_deque.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 6 votes |
def test_main(verbose=None): import sys test_classes = ( TestBasic, TestVariousIteratorArgs, TestSubclass, TestSubclassWithKwargs, TestSequence, ) support.run_unittest(*test_classes) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_unittest(*test_classes) gc.collect() counts[i] = sys.gettotalrefcount() print(counts) # doctests from test import test_deque support.run_doctest(test_deque, verbose)
Example #2
Source File: test_deque.py From ironpython3 with Apache License 2.0 | 6 votes |
def test_main(verbose=None): import sys test_classes = ( TestBasic, TestVariousIteratorArgs, TestSubclass, TestSubclassWithKwargs, ) support.run_unittest(*test_classes) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_unittest(*test_classes) gc.collect() counts[i] = sys.gettotalrefcount() print(counts) # doctests from test import test_deque support.run_doctest(test_deque, verbose)
Example #3
Source File: test_itertools.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 6 votes |
def test_main(verbose=None): test_classes = (TestBasicOps, TestVariousIteratorArgs, TestGC, RegressionTests, LengthTransparency, SubclassWithKwargsTest, TestExamples, SizeofTest) support.run_unittest(*test_classes) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_unittest(*test_classes) gc.collect() counts[i] = sys.gettotalrefcount() print(counts) # doctest the examples in the library reference support.run_doctest(sys.modules[__name__], verbose)
Example #4
Source File: test_itertools.py From ironpython3 with Apache License 2.0 | 6 votes |
def test_main(verbose=None): test_classes = (TestBasicOps, TestVariousIteratorArgs, TestGC, RegressionTests, LengthTransparency, SubclassWithKwargsTest, TestExamples, SizeofTest) support.run_unittest(*test_classes) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_unittest(*test_classes) gc.collect() counts[i] = sys.gettotalrefcount() print(counts) # doctest the examples in the library reference support.run_doctest(sys.modules[__name__], verbose)
Example #5
Source File: test_itertools.py From Fluid-Designer with GNU General Public License v3.0 | 6 votes |
def test_main(verbose=None): test_classes = (TestBasicOps, TestVariousIteratorArgs, TestGC, RegressionTests, LengthTransparency, SubclassWithKwargsTest, TestExamples, SizeofTest) support.run_unittest(*test_classes) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_unittest(*test_classes) gc.collect() counts[i] = sys.gettotalrefcount() print(counts) # doctest the examples in the library reference support.run_doctest(sys.modules[__name__], verbose)
Example #6
Source File: test_deque.py From Fluid-Designer with GNU General Public License v3.0 | 6 votes |
def test_main(verbose=None): import sys test_classes = ( TestBasic, TestVariousIteratorArgs, TestSubclass, TestSubclassWithKwargs, TestSequence, ) support.run_unittest(*test_classes) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_unittest(*test_classes) gc.collect() counts[i] = sys.gettotalrefcount() print(counts) # doctests from test import test_deque support.run_doctest(test_deque, verbose)
Example #7
Source File: test_weakref.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(): support.run_unittest( ReferencesTestCase, WeakMethodTestCase, MappingTestCase, WeakValueDictionaryTestCase, WeakKeyDictionaryTestCase, SubclassableWeakrefTestCase, FinalizeTestCase, ) support.run_doctest(sys.modules[__name__])
Example #8
Source File: test_cmd.py From ironpython3 with Apache License 2.0 | 5 votes |
def test_main(verbose=None): from test import test_cmd support.run_doctest(test_cmd, verbose) support.run_unittest(TestAlternateInput)
Example #9
Source File: test_pickletools.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(): support.run_unittest(OptimizedPickleTests) support.run_doctest(pickletools)
Example #10
Source File: test_doctest.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(): # Check the doctest cases in doctest itself: ret = support.run_doctest(doctest, verbosity=True) # Check the doctest cases defined here: from test import test_doctest support.run_doctest(test_doctest, verbosity=True)
Example #11
Source File: test_collections.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=None): NamedTupleDocs = doctest.DocTestSuite(module=collections) test_classes = [TestNamedTuple, NamedTupleDocs, TestOneTrickPonyABCs, TestCollectionABCs, TestCounter, TestChainMap, TestUserObjects, ] support.run_unittest(*test_classes) support.run_doctest(collections, verbose)
Example #12
Source File: test_metaclass.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=False): from test import support from test import test_metaclass support.run_doctest(test_metaclass, verbose)
Example #13
Source File: test_unpack.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=False): from test import support from test import test_unpack support.run_doctest(test_unpack, verbose)
Example #14
Source File: test_descrtut.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=None): # Obscure: import this module as test.test_descrtut instead of as # plain test_descrtut because the name of this module works its way # into the doctest examples, and unless the full test.test_descrtut # business is used the name can change depending on how the test is # invoked. from test import support, test_descrtut support.run_doctest(test_descrtut, verbose) # This part isn't needed for regrtest, but for running the test directly.
Example #15
Source File: test_genexps.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=None): from test import support from test import test_genexps support.run_doctest(test_genexps, verbose) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_doctest(test_genexps, verbose) gc.collect() counts[i] = sys.gettotalrefcount() print(counts)
Example #16
Source File: test_syntax.py From ironpython3 with Apache License 2.0 | 5 votes |
def test_main(): support.run_unittest(SyntaxTestCase) from test import test_syntax support.run_doctest(test_syntax, verbosity=True)
Example #17
Source File: test_listcomps.py From ironpython3 with Apache License 2.0 | 5 votes |
def test_main(verbose=None): import sys from test import support from test import test_listcomps support.run_doctest(test_listcomps, verbose) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_doctest(test_genexps, verbose) gc.collect() counts[i] = sys.gettotalrefcount() print(counts)
Example #18
Source File: test_setcomps.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=None): import sys from test import support from test import test_setcomps support.run_doctest(test_setcomps, verbose) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_doctest(test_setcomps, verbose) gc.collect() counts[i] = sys.gettotalrefcount() print(counts)
Example #19
Source File: test_listcomps.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=None): import sys from test import support from test import test_listcomps support.run_doctest(test_listcomps, verbose) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_doctest(test_genexps, verbose) gc.collect() counts[i] = sys.gettotalrefcount() print(counts)
Example #20
Source File: test_pickle.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(): tests = [PickleTests, PyUnpicklerTests, PyPicklerTests, PyPersPicklerTests, PyIdPersPicklerTests, PyDispatchTableTests, PyChainDispatchTableTests, CompatPickleTests] if has_c_implementation: tests.extend([CUnpicklerTests, CPicklerTests, CPersPicklerTests, CIdPersPicklerTests, CDumpPickle_LoadPickle, DumpPickle_CLoadPickle, PyPicklerUnpicklerObjectTests, CPicklerUnpicklerObjectTests, CDispatchTableTests, CChainDispatchTableTests, InMemoryPickleTests, SizeofTests]) support.run_unittest(*tests) support.run_doctest(pickle)
Example #21
Source File: test_generators.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=None): from test import support, test_generators support.run_unittest(__name__) support.run_doctest(test_generators, verbose) # This part isn't needed for regrtest, but for running the test directly.
Example #22
Source File: test_cmd.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(verbose=None): from test import test_cmd support.run_doctest(test_cmd, verbose) support.run_unittest(TestAlternateInput)
Example #23
Source File: test_syntax.py From Project-New-Reign---Nemesis-Main with GNU General Public License v3.0 | 5 votes |
def test_main(): support.run_unittest(SyntaxTestCase) from test import test_syntax support.run_doctest(test_syntax, verbosity=True)
Example #24
Source File: test_genexps.py From android_universal with MIT License | 5 votes |
def test_main(verbose=None): from test import support from test import test_genexps support.run_doctest(test_genexps, verbose) # verify reference counting if verbose and hasattr(sys, "gettotalrefcount"): import gc counts = [None] * 5 for i in range(len(counts)): support.run_doctest(test_genexps, verbose) gc.collect() counts[i] = sys.gettotalrefcount() print(counts)
Example #25
Source File: test_descrtut.py From android_universal with MIT License | 5 votes |
def test_main(verbose=None): # Obscure: import this module as test.test_descrtut instead of as # plain test_descrtut because the name of this module works its way # into the doctest examples, and unless the full test.test_descrtut # business is used the name can change depending on how the test is # invoked. from test import support, test_descrtut support.run_doctest(test_descrtut, verbose) # This part isn't needed for regrtest, but for running the test directly.
Example #26
Source File: test_unpack.py From android_universal with MIT License | 5 votes |
def test_main(verbose=False): from test import support from test import test_unpack support.run_doctest(test_unpack, verbose)
Example #27
Source File: test_metaclass.py From android_universal with MIT License | 5 votes |
def test_main(verbose=False): from test import support from test import test_metaclass support.run_doctest(test_metaclass, verbose)
Example #28
Source File: test_collections.py From android_universal with MIT License | 5 votes |
def test_main(verbose=None): NamedTupleDocs = doctest.DocTestSuite(module=collections) test_classes = [TestNamedTuple, NamedTupleDocs, TestOneTrickPonyABCs, TestCollectionABCs, TestCounter, TestChainMap, TestUserObjects, ] support.run_unittest(*test_classes) support.run_doctest(collections, verbose)
Example #29
Source File: test_doctest.py From android_universal with MIT License | 5 votes |
def test_main(): # Check the doctest cases in doctest itself: ret = support.run_doctest(doctest, verbosity=True) # Check the doctest cases defined here: from test import test_doctest support.run_doctest(test_doctest, verbosity=True) # Run unittests support.run_unittest(__name__)
Example #30
Source File: test_pickletools.py From android_universal with MIT License | 5 votes |
def test_main(): support.run_unittest(OptimizedPickleTests) support.run_unittest(MiscTestCase) support.run_doctest(pickletools)