Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/libs/python/example/test_getting_started1.py @ 29

Last change on this file since 29 was 29, checked in by landauf, 17 years ago

updated boost from 1_33_1 to 1_34_1

File size: 645 bytes
Line 
1# Copyright Ralf W. Grosse-Kunstleve 2006. Distributed under the Boost
2# Software License, Version 1.0. (See accompanying
3# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
4r'''>>> import getting_started1
5    >>> print getting_started1.greet()
6    hello, world
7    >>> number = 11
8    >>> print number, '*', number, '=', getting_started1.square(number)
9    11 * 11 = 121
10'''
11
12def run(args = None):
13    if args is not None:
14        import sys
15        sys.argv = args
16    import doctest, test_getting_started1
17    return doctest.testmod(test_getting_started1)
18
19if __name__ == '__main__':
20    import sys
21    sys.exit(run()[0])
Note: See TracBrowser for help on using the repository browser.