facebook / facebook/TestSlide

Suggest mock_(async)_callable from StrictMock

未关闭
#128 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
Better Error Messages enhancement good first issue help wanted StrictMock
主要语言
Python
星标
149
派生
62
PR 合并指标
30 天内没有已合并 PR

描述

StrictMock raises when an attribute is accessed, but has not been previously defined

https://github.com/facebookincubator/TestSlide/blob/8d516487247b6591c5a310c3e069ddb32d822d5f/testslide/strict_mock.py#L70

The message simply mentions "setting" the attribute. Let's improve this message to, if the mock has a template, and the attribute is callable, suggest using mock_callable / mock_async_callable to set it.

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。