原文链接:http://www.cnblogs.com/Detector/p/8477276.html
xUnit frameworks 单元测试框架
frameworks 框架
extensions 扩展
proboscis - 仿TestNG扩展了unittest模块以及Nose的功能grail - 可以让你一步一步编写测试用例的库testify - 单元测试框架,提供了加强型fixture,用例切割并行运行,testrunner高亮及详尽的log和report功能trial - unittest模块的扩展,提供了命令行的testrunner工具以及代码覆盖率的整合,跟nose差不多subunit - 提供了unittest在另一个进程执行用例并汇总测试数据的能力testresources - 提供了多用例间管理测试数据的机制,兼容unittesttesttools - 为Twisted和Bazaar提供的unittest扩展Sancho - 运行用例,并为失败的用例提供报告,但仅限于此zope.testing - testrunner,提供了不错的debuge能力,并且集成了代码覆盖率。可以跟zope项目使用,也可以用在非zope项目上pythoscope - 自动或半自动为遗留的python系统创建测试用例的工具testlib - 更强大的unittest,更多的断言,支持module级的setup/teardown,skip test等...dutest - An object oriented interface to retrieve unittest test cases out of doctests. Hides initialization from doctests by allowing setUp and tearDown for each interactive example. Allows control over all the options provided by doctest. Specialized classes allow selective test discovery across a package hierarchy.green - Green是一个简洁多彩的testrunner,跟nose很像ddt - 让unittest 支持 Data-Drivenpytractor Selenium python bindings的扩展. 目的是让angular项目的测试更简单
TDD ATDD BDD 测试框架
BDD
Assertions 断言
pyshould - 基于pyhamcrest的Should style断言pyhamcrest - python版的Hamcrest matcherssure -python实现的测试库,提供了强大灵活的断言assertpy - 巨简单的python单元测试断言库,提供了优雅流利的API. 支持Python 2 和 3. Mocking
mock - python实现的Mocking和Patching库Ludibrio - 用python实现的优雅的test doubles框架(mocks, stubs, spy, and dummies).responses - mock请求的 Python测试工具库doublex - 强大的 test doubles 框架freezegun - 通过mocking datetime模块实现时光穿梭httpretty - HTTP请求的mock工具httmock - requests的mock工具,支持Python 2.6+ and 3.2+.pretenders - 测试用的fake servermock-server - 简单的mock sever,支持REST and XML-RPC API,还有基于tornado的管理界面VCR.py - 自动 mock HTTP 交互 让测试更简单快速