Staging
v0.8.1
v0.8.1
Revision 663836e1179ea79eac12e55670af7e89a531a060 authored by Miss Islington (bot) on 10 June 2020, 01:26:16 UTC, committed by GitHub on 10 June 2020, 01:26:16 UTC
Follow-up to GH-8014 (cherry picked from commit 7aed0524d4129766a6032326949ef7f91f6f6dfc) Co-authored-by: Éric Araujo <merwok@netwok.org> Automerge-Triggered-By: @merwok
1 parent 0f5a28f
sample_doctest.py
"""This is a sample module that doesn't really test anything all that
interesting.
It simply has a few tests, some of which succeed and some of which fail.
It's important that the numbers remain constant as another test is
testing the running of these tests.
>>> 2+2
4
"""
def foo():
"""
>>> 2+2
5
>>> 2+2
4
"""
def bar():
"""
>>> 2+2
4
"""
def test_silly_setup():
"""
>>> import test.test_doctest
>>> test.test_doctest.sillySetup
True
"""
def w_blank():
"""
>>> if 1:
... print('a')
... print()
... print('b')
a
<BLANKLINE>
b
"""
x = 1
def x_is_one():
"""
>>> x
1
"""
def y_is_one():
"""
>>> y
1
"""
__test__ = {'good': """
>>> 42
42
""",
'bad': """
>>> 42
666
""",
}
def test_suite():
import doctest
return doctest.DocTestSuite()
Computing file changes ...