facebook/TestSlide

Support for classes that define `__new__` for `mock_constructor`

Open

#155 geöffnet am 9. Apr. 2020

Auf GitHub ansehen
 (1 Kommentar) (0 Reaktionen) (1 zugewiesene Person)Python (58 Forks)auto 404
enhancementhelp wantedmock_constructor

Repository-Metriken

Stars
 (147 Stars)
PR-Merge-Metriken
 (PR-Metriken ausstehend)

Beschreibung

It currently has no support for classes with __new__, and will reject patching those.

IIRC, it was tough getting around Python idiosyncrasies to make mock_constructor work, and I willingly decided not to implement __new__ at first to simplify things, but this is potentially doable.

Contributor Guide