用于处理文件和命令的代码的测试实用程序
testpath的Python项目详细描述
testpath是python代码处理文件和命令的实用程序的集合。
它包含用于检查文件系统上的内容的函数,以及用于模拟的工具 系统命令和录音呼叫。
例如:
import testpath testpath.assert_isfile(path) with testpath.assert_calls('git', ['add', path]): function_under_test()
用于处理文件和命令的代码的测试实用程序
testpath是python代码处理文件和命令的实用程序的集合。
它包含用于检查文件系统上的内容的函数,以及用于模拟的工具 系统命令和录音呼叫。
例如:
import testpath testpath.assert_isfile(path) with testpath.assert_calls('git', ['add', path]): function_under_test()