fname stringlengths 63 176 | rel_fname stringclasses 706
values | line int64 -1 4.5k | name stringlengths 1 81 | kind stringclasses 2
values | category stringclasses 2
values | info stringlengths 0 77.9k ⌀ |
|---|---|---|---|---|---|---|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 673 | assertoutcome | ref | function | reprec.assertoutcome(failed=1, passed=0)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 675 | test_contains_unicode | def | function | def test_contains_unicode(self, pytester: Pytester):
"""Fix internal error with docstrings containing non-ascii characters."""
pytester.makepyfile(
'''\
def foo():
"""
>>> name = 'с' # not letter 'c' but instead Cyrillic 's'.
'a... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 677 | makepyfile | ref | function | pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 686 | runpytest | ref | function | result = pytester.runpytest("--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 687 | fnmatch_lines | ref | function | result.stdout.fnmatch_lines(["Got nothing", "* 1 failed in*"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 689 | test_ignore_import_errors_on_doctest | def | function | def test_ignore_import_errors_on_doctest(self, pytester: Pytester):
p = pytester.makepyfile(
"""
import asdf
def add_one(x):
'''
>>> add_one(1)
2
'''
return x + 1
"""
)
... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 690 | makepyfile | ref | function | p = pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 703 | inline_run | ref | function | reprec = pytester.inline_run(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 706 | assertoutcome | ref | function | reprec.assertoutcome(skipped=1, failed=1, passed=0)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 708 | test_junit_report_for_doctest | def | function | def test_junit_report_for_doctest(self, pytester: Pytester):
"""#713: Fix --junit-xml option when used with --doctest-modules."""
p = pytester.makepyfile(
"""
def foo():
'''
>>> 1 + 1
3
'''
pass
... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 710 | makepyfile | ref | function | p = pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 720 | inline_run | ref | function | reprec = pytester.inline_run(p, "--doctest-modules", "--junit-xml=junit.xml")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 721 | assertoutcome | ref | function | reprec.assertoutcome(failed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 723 | test_unicode_doctest | def | function | def test_unicode_doctest(self, pytester: Pytester):
"""
Test case for issue 2434: DecodeError on Python 2 when doctest contains non-ascii
characters.
"""
p = pytester.maketxtfile(
test_unicode_doctest="""
.. doctest::
>>> print("Hi\\n\... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 728 | maketxtfile | ref | function | p = pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 740 | runpytest | ref | function | result = pytester.runpytest(p)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 741 | fnmatch_lines | ref | function | result.stdout.fnmatch_lines(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 745 | test_unicode_doctest_module | def | function | def test_unicode_doctest_module(self, pytester: Pytester):
"""
Test case for issue 2434: DecodeError on Python 2 when doctest docstring
contains non-ascii characters.
"""
p = pytester.makepyfile(
test_unicode_doctest_module="""
def fix_bad_unicode(text... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 750 | makepyfile | ref | function | p = pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 760 | runpytest | ref | function | result = pytester.runpytest(p, "--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 761 | fnmatch_lines | ref | function | result.stdout.fnmatch_lines(["* 1 passed *"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 763 | test_print_unicode_value | def | function | def test_print_unicode_value(self, pytester: Pytester):
"""
Test case for issue 3583: Printing Unicode in doctest under Python 2.7
doesn't work
"""
p = pytester.maketxtfile(
test_print_unicode_value=r"""
Here is a doctest::
>>> print('... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 768 | maketxtfile | ref | function | p = pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 776 | runpytest | ref | function | result = pytester.runpytest(p)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 777 | fnmatch_lines | ref | function | result.stdout.fnmatch_lines(["* 1 passed *"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 779 | test_reportinfo | def | function | def test_reportinfo(self, pytester: Pytester):
"""Make sure that DoctestItem.reportinfo() returns lineno."""
p = pytester.makepyfile(
test_reportinfo="""
def foo(x):
'''
>>> foo('a')
'b'
'''
... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 781 | makepyfile | ref | function | p = pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 791 | inline_genitems | ref | function | items, reprec = pytester.inline_genitems(p, "--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 792 | reportinfo | ref | function | reportinfo = items[0].reportinfo()
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 795 | test_valid_setup_py | def | function | def test_valid_setup_py(self, pytester: Pytester):
"""
Test to make sure that pytest ignores valid setup.py files when ran
with --doctest-modules
"""
p = pytester.makepyfile(
setup="""
from setuptools import setup, find_packages
setup(name=... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 800 | makepyfile | ref | function | p = pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 810 | runpytest | ref | function | result = pytester.runpytest(p, "--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 811 | fnmatch_lines | ref | function | result.stdout.fnmatch_lines(["*collected 0 items*"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 813 | test_invalid_setup_py | def | function | def test_invalid_setup_py(self, pytester: Pytester):
"""
Test to make sure that pytest reads setup.py files that are not used
for python packages when ran with --doctest-modules
"""
p = pytester.makepyfile(
setup="""
def test_foo():
ret... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 818 | makepyfile | ref | function | p = pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 824 | runpytest | ref | function | result = pytester.runpytest(p, "--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 825 | fnmatch_lines | ref | function | result.stdout.fnmatch_lines(["*collected 1 item*"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 828 | TestLiterals | def | class | test_allow_unicode test_allow_bytes test_unicode_string test_bytes_literal test_number_re test_number_precision test_number_non_matches test_number_and_allow_unicode |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 829 | parametrize | ref | function | @pytest.mark.parametrize("config_mode", ["ini", "comment"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 830 | test_allow_unicode | def | function | def test_allow_unicode(self, pytester, config_mode):
"""Test that doctests which output unicode work in all python versions
tested by pytest when the ALLOW_UNICODE option is used (either in
the ini file or by an inline comment).
"""
if config_mode == "ini":
pytest... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 836 | makeini | ref | function | pytester.makeini(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 846 | maketxtfile | ref | function | pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 854 | makepyfile | ref | function | pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 865 | inline_run | ref | function | reprec = pytester.inline_run("--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 866 | assertoutcome | ref | function | reprec.assertoutcome(passed=2)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 868 | parametrize | ref | function | @pytest.mark.parametrize("config_mode", ["ini", "comment"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 869 | test_allow_bytes | def | function | def test_allow_bytes(self, pytester, config_mode):
"""Test that doctests which output bytes work in all python versions
tested by pytest when the ALLOW_BYTES option is used (either in
the ini file or by an inline comment)(#1287).
"""
if config_mode == "ini":
pytes... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 875 | makeini | ref | function | pytester.makeini(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 885 | maketxtfile | ref | function | pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 893 | makepyfile | ref | function | pytester.makepyfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 904 | inline_run | ref | function | reprec = pytester.inline_run("--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 905 | assertoutcome | ref | function | reprec.assertoutcome(passed=2)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 907 | test_unicode_string | def | function | def test_unicode_string(self, pytester: Pytester):
"""Test that doctests which output unicode fail in Python 2 when
the ALLOW_UNICODE option is not used. The same test should pass
in Python 3.
"""
pytester.maketxtfile(
test_doc="""
>>> b'12'.decode('as... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 912 | maketxtfile | ref | function | pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 918 | inline_run | ref | function | reprec = pytester.inline_run()
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 919 | assertoutcome | ref | function | reprec.assertoutcome(passed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 921 | test_bytes_literal | def | function | def test_bytes_literal(self, pytester: Pytester):
"""Test that doctests which output bytes fail in Python 3 when
the ALLOW_BYTES option is not used. (#1287).
"""
pytester.maketxtfile(
test_doc="""
>>> b'foo'
'foo'
"""
)
repr... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 925 | maketxtfile | ref | function | pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 931 | inline_run | ref | function | reprec = pytester.inline_run()
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 932 | assertoutcome | ref | function | reprec.assertoutcome(failed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 934 | test_number_re | def | function | def test_number_re(self) -> None:
_number_re = _get_checker()._number_re # type: ignore
for s in [
"1.",
"+1.",
"-1.",
".1",
"+.1",
"-.1",
"0.1",
"+0.1",
"-0.1",
"1e5",
... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 935 | _get_checker | ref | function | _number_re = _get_checker()._number_re # type: ignore
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 959 | approx | ref | function | assert float(m.group()) == pytest.approx(float(s))
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 964 | parametrize | ref | function | @pytest.mark.parametrize("config_mode", ["ini", "comment"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 965 | test_number_precision | def | function | def test_number_precision(self, pytester, config_mode):
"""Test the NUMBER option."""
if config_mode == "ini":
pytester.makeini(
"""
[pytest]
doctest_optionflags = NUMBER
"""
)
comment = ""
el... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 968 | makeini | ref | function | pytester.makeini(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 978 | maketxtfile | ref | function | pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,035 | inline_run | ref | function | reprec = pytester.inline_run()
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,036 | assertoutcome | ref | function | reprec.assertoutcome(passed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,038 | parametrize | ref | function | @pytest.mark.parametrize(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,056 | param | ref | function | pytest.param("'3.1416'", "'3.14'", marks=pytest.mark.xfail),
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,059 | test_number_non_matches | def | function | def test_number_non_matches(self, pytester, expression, output):
pytester.maketxtfile(
test_doc="""
>>> {expression} #doctest: +NUMBER
{output}
""".format(
expression=expression, output=output
)
)
reprec = pytester.i... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,060 | maketxtfile | ref | function | pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,068 | inline_run | ref | function | reprec = pytester.inline_run()
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,069 | assertoutcome | ref | function | reprec.assertoutcome(passed=0, failed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,071 | test_number_and_allow_unicode | def | function | def test_number_and_allow_unicode(self, pytester: Pytester):
pytester.maketxtfile(
test_doc="""
>>> from collections import namedtuple
>>> T = namedtuple('T', 'a b c')
>>> T(a=0.2330000001, b=u'str', c=b'bytes') # doctest: +ALLOW_UNICODE, +ALLOW_BYTES, +NUMBER... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,072 | maketxtfile | ref | function | pytester.maketxtfile(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,080 | inline_run | ref | function | reprec = pytester.inline_run()
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,081 | assertoutcome | ref | function | reprec.assertoutcome(passed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,084 | TestDoctestSkips | def | class | makedoctest test_one_skipped test_one_skipped_failed test_all_skipped test_vacuous_all_skipped test_continue_on_failure |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,090 | fixture | ref | function | @pytest.fixture(params=["text", "module"])
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,091 | makedoctest | def | function | def makedoctest(self, pytester, request):
def makeit(doctest):
mode = request.param
if mode == "text":
pytester.maketxtfile(doctest)
else:
assert mode == "module"
pytester.makepyfile('"""\n%s"""' % doctest)
return m... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,092 | makeit | def | function | def makeit(doctest):
mode = request.param
if mode == "text":
pytester.maketxtfile(doctest)
else:
assert mode == "module"
pytester.makepyfile('"""\n%s"""' % doctest)
return makeit
def test_one_skipped(self, pytester... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,095 | maketxtfile | ref | function | pytester.maketxtfile(doctest)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,098 | makepyfile | ref | function | pytester.makepyfile('"""\n%s"""' % doctest)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,102 | test_one_skipped | def | function | def test_one_skipped(self, pytester, makedoctest):
makedoctest(
"""
>>> 1 + 1 # doctest: +SKIP
2
>>> 2 + 2
4
"""
)
reprec = pytester.inline_run("--doctest-modules")
reprec.assertoutcome(passed=1)
def test_one_s... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,103 | makedoctest | ref | function | makedoctest(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,111 | inline_run | ref | function | reprec = pytester.inline_run("--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,112 | assertoutcome | ref | function | reprec.assertoutcome(passed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,114 | test_one_skipped_failed | def | function | def test_one_skipped_failed(self, pytester, makedoctest):
makedoctest(
"""
>>> 1 + 1 # doctest: +SKIP
2
>>> 2 + 2
200
"""
)
reprec = pytester.inline_run("--doctest-modules")
reprec.assertoutcome(failed=1)
def t... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,115 | makedoctest | ref | function | makedoctest(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,123 | inline_run | ref | function | reprec = pytester.inline_run("--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,124 | assertoutcome | ref | function | reprec.assertoutcome(failed=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,126 | test_all_skipped | def | function | def test_all_skipped(self, pytester, makedoctest):
makedoctest(
"""
>>> 1 + 1 # doctest: +SKIP
2
>>> 2 + 2 # doctest: +SKIP
200
"""
)
reprec = pytester.inline_run("--doctest-modules")
reprec.assertoutcome(skipped=1... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,127 | makedoctest | ref | function | makedoctest(
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,135 | inline_run | ref | function | reprec = pytester.inline_run("--doctest-modules")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,136 | assertoutcome | ref | function | reprec.assertoutcome(skipped=1)
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,138 | test_vacuous_all_skipped | def | function | def test_vacuous_all_skipped(self, pytester, makedoctest):
makedoctest("")
reprec = pytester.inline_run("--doctest-modules")
reprec.assertoutcome(passed=0, skipped=0)
def test_continue_on_failure(self, pytester: Pytester):
pytester.maketxtfile(
test_something="""
... |
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,139 | makedoctest | ref | function | makedoctest("")
|
playground/385a4687-3c82-4369-b8de-c1d8c2e759f9/pytest/testing/test_doctest.py | testing/test_doctest.py | 1,140 | inline_run | ref | function | reprec = pytester.inline_run("--doctest-modules")
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.