def test_collect_module_single_modulelevel_doctest(self, testdir):
    path = testdir.makepyfile(whatever='""">>> pass"""')
    for p in (path, testdir.tmpdir):
        (items, reprec) = testdir.inline_genitems(p, '--doctest-modules')
        assert (len(items) == 1)
        assert isinstance(items[0], DoctestItem)
        assert isinstance(items[0].parent, DoctestModule)
def test_collect_module_single_modulelevel_doctest(self, testdir):
    path = testdir.makepyfile(whatever='">>> pass"')
    for p in (path, testdir.tmpdir):
        (items, reprec) = testdir.inline_genitems(p, '--doctest-modules')
        assert (len(items) == 1)
        assert isinstance(items[0], DoctestItem)
        assert isinstance(items[0].parent, DoctestModule)