2
0
mirror of https://github.com/boostorg/python.git synced 2026-01-22 05:22:45 +00:00
Files
python/example/test_rwgk1.py
Dave Abrahams 4328ae1d8d Updates for Boost.Build
[SVN r10403]
2001-06-22 22:36:00 +00:00

20 lines
397 B
Python

r'''>>> import rwgk1
>>> print rwgk1.greet()
hello, world
>>> number = 11
>>> print number, '*', number, '=', rwgk1.square(number)
11 * 11 = 121
'''
def run(args = None):
if args is not None:
import sys
sys.argv = args
import doctest, test_rwgk1
return doctest.testmod(test_rwgk1)
if __name__ == '__main__':
import sys
sys.exit(run()[0])