Python解释器环境与选项
Python解释器环境变量
python 文档字符串
doctest模块
可以测试模块字符串文档正确性的测试:
dir(doctest)
[‘BLANKLINE_MARKER’, ‘COMPARISON_FLAGS’, ‘DONT_ACCEPT_BLANKLINE’, ‘DONT_ACCEPT_TRUE_FOR_1’, ‘DebugRunner’, ‘DocFileCase’, ‘DocFileSuite’, ‘DocFileTest’, ‘DocTest’, ‘DocTestCase’, ‘DocTestFailure’, ‘DocTestFinder’, ‘DocTestParser’, ‘DocTestRunner’, ‘DocTestSuite’, ‘ELLIPSIS’, ‘ELLIPSIS_MARKER’, ‘Example’, ‘FAIL_FAST’, ‘IGNORE_EXCEPTION_DETAIL’, ‘NORMALIZE_WHITESPACE’, ‘OPTIONFLAGS_BY_NAME’, ‘OutputChecker’, ‘REPORTING_FLAGS’, ‘REPORT_CDIFF’, ‘REPORT_NDIFF’, ‘REPORT_ONLY_FIRST_FAILURE’, ‘REPORT_UDIFF’, ‘SKIP’, ‘SkipDocTestCase’, ‘StringIO’, ‘TestResults’, ‘UnexpectedException’, ‘_DocTestSuite’, ’ _ OutputRedirectingPdb’, ‘_SpoofOut’, ‘_TestClass’, ’ __ al l __ ‘, ’ __ builtins __ ‘, ’ __ cached __’, ’ __ doc __’, ’ __ docformat __ ‘, ’ __ file __’, ’ __ future __ ‘, ’ __ loader __’, ’ __ name __ ', ’ __ package __ ', ’ __ spec __ ', ’ __ test __ ', ‘_comment_line’, ‘_ellipsis_match’, ‘_exception_traceback’, ‘_extract_future_flags’, ‘_indent’, ‘_load_testfile’, ‘_module_relative_path’, ‘_normalize_module’, ‘_strip_exception_details’, ‘_test’, ‘_unittest_reportflags’, ‘argparse’, ‘debug’, ‘debug_script’, ‘debug_src’, ‘difflib’, ‘inspect’, ‘linecache’, ‘master’, ‘namedtuple’, ‘os’, ‘pdb’, ‘re’, ‘register_optionflag’, ‘run_docstring_examples’, ‘script_from_examples’, ‘set_unittest_reportflags’, ‘sys’, ‘testfile’, ‘testmod’, ‘testsource’, ‘traceback’, ‘unittest’]
完结
python 基础简介完成,后续可能会继续更新。