1 """A module to test whether doctest recognizes some 2.2 features,
2 like static and class methods.
8 from test
import test_support
53 def setx(self
, value
):
62 x
= property(getx
, setx
, doc
="""\
73 >>> print C.statm() # 16
75 >>> print C().statm() # 17
80 statm
= staticmethod(statm
)
86 >>> print C.clsm(22) # 18
88 >>> print C().clsm(23) # 19
93 clsm
= classmethod(clsm
)
96 from test
import test_doctest2
98 f
, t
= test_support
.run_doctest(test_doctest2
)
100 raise test_support
.TestFailed("expected %d tests to run, not %d" %
103 # Pollute the namespace with a bunch of imported functions and classes,
104 # to make sure they don't get tested.
105 from doctest
import *
107 if __name__
== '__main__':