facebook / facebook/TestSlide

Suggest mock_(async)_callable from StrictMock

Aperta
#128 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Better Error Messages enhancement good first issue help wanted StrictMock
Lingua principale
Python
Stelle
149
Fork
62
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

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.

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.