blob: 25a1d374647575f7cfa7bffcd86047955afae127 [file] [log] [blame]
Tim Peters19397e52004-08-06 22:02:59 +00001"""This is a sample module that doesn't really test anything all that
2 interesting
3
4It simply has a few tests, some of which suceed and some of which fail.
5
6It's important that the numbers remain constance, as another test is
7testing the running of these tests.
8
9
10>>> 2+2
114
12"""
13
14
15def foo():
16 """
17
18 >>> 2+2
19 5
20
21 >>> 2+2
22 4
23 """
24
25def bar():
26 """
27
28 >>> 2+2
29 4
30 """
31
32def test_silly_setup():
33 """
34
35 >>> import test.test_doctest
36 >>> test.test_doctest.sillySetup
37 True
38 """
39
40def w_blank():
41 """
42 >>> if 1:
43 ... print 'a'
44 ... print
45 ... print 'b'
46 a
47 <BLANKLINE>
48 b
49 """
50
51x = 1
52def x_is_one():
53 """
54 >>> x
55 1
56 """
57
58def y_is_one():
59 """
60 >>> y
61 1
62 """
63
64def test_suite():
65 import doctest
66 return doctest.DocTestSuite()