基于假设属性测试的命令行界面

hypothit的Python项目详细描述


下击

PyPI badgeDocumentation StatusCI badge

基于假设属性测试的命令行界面

$ hypothit trial --given "a=integers()" --assume 'a!=0' "assert a==42"
from hypothesis import given, assume
from hypothesis.strategies import integers


@given(a=integers())
def inner(a):
    assume(a!=0)
    assert a==42

inner()

Falsifying example: inner(a=1)
Traceback (most recent call last):
File ".../hypothit/cli.py", line 90, in trial
    exec(src, g)
File "<string>", line 10, in <module>
File "<string>", line 6, in inner
File ".../hypothesis/core.py", line 1024, in wrapped_test
    raise the_error_hypothesis_found
File "<string>", line 8, in inner
AssertionError

学分

这个包是用Cookiecutter,&;audreyr/cookiecutter-pypackage剪切的。

历史记录

0.1.0(2019-05-01)

  • pypi上的第一个版本。

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
Android中Axis2 web服务的java解析响应   java读取Dockerfile命令时遇到问题:是否可以将cd刻录到jar文件中?那么tarcf是做什么的呢?   java如何防止gcmTaskService periodicTask在上一个任务尚未完成时再次运行?   jquery希望使用Java生成自动登录程序   在Hibernate中检索用BigInteger映射的属性时出现java问题   与错误用户连接时发生java错误   java Hibernate+c3p0池+ehcache失败启动   JAVAlang.ClassNotFoundException:org。mysql。JDBC无法解决,添加了mysql连接器   java如何在其键包含JSTL中的点时访问映射值?   packageprivate类中的Java方法可访问性?   java如何将文件转换为StorageObject(谷歌API)   java apache commons httpclient 4.23表单登录问题不同请求中使用的不同会话cookie   所有组件的java一个侦听器instance或每个组件的一个实例   重新启动应用程序后,不会保存ListView中的java更新   java如何修复libgdx中的屏幕无渲染   java在使用mongotemplate时遇到ClassNotFound异常