aboutsummaryrefslogtreecommitdiffstats
path: root/python-packages/order_utils/test/test_doctest.py
blob: f692b3b6cf962b0d21a6a3deab83cda9ece2984e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
"""Exercise doctests for all of our modules."""

from doctest import testmod
import pkgutil

import zero_ex


def test_all_doctests():
    """Gather zero_ex.* modules and doctest them."""
    for (importer, modname, _) in pkgutil.walk_packages(
        path=zero_ex.__path__, prefix="zero_ex."
    ):
        module = importer.find_module(modname).load_module(modname)
        print(module)
        (failure_count, _) = testmod(module)
        assert failure_count == 0