跳转到主要内容

未知

项目描述

一个鼻子插件,为每个测试将一个cProfile状态转储输出到一个文件。

安装

pip install nose-talisker

文件名格式为

module-name.class-name.test-name.elapsed-milli-seconds.timestamp.prof

例如

zamboni.apps.files.tests.test_views.TestFileViewer.test_view_access_reviewed.001448ms.2011-06-09T01:50:34.323206.prof
zamboni.apps.files.tests.test_views.TestFileViewer.test_view_access_reviewed.001577ms.2011-06-09T01:56:51.694283.prof

选项

  • prof_path: 要写入的目标目录。如果没有给出,将为您创建一个临时目录。如果您提供一个目录,则它必须存在。

用法

nosetests –with-talisker –prof-path=/tmp/output

此模块设计用于由talisker使用来消费和查看配置文件结果。格式故意基于命令扩展模块中的runprofileserver,具有相同的选项命名。

许可证: BSD 作者: Andy McKay, andym@mozilla.com

由以下支持