Тёмный
No video :(

Edwin Jung - Mocking and Patching Pitfalls - PyCon 2019 

PyCon 2019
Подписаться 14 тыс.
Просмотров 12 тыс.
50% 1

"Speaker: Edwin Jung
Mocking and patching are powerful techniques for testing, but they can be easily abused, with negative effects on code quality, maintenance, and application architecture. These pain-points can be hard to verbalize, and consequently hard to address. If your unit tests are a PITA, but you cannot explain why, this talk may be for you.
Mocking as a technique has deep roots within OOD and TDD, going back 20+ years, but many Python developers know mocks and patches merely as a technique to isolate code under test. In the absence of knowledge around OOD and TDD, best practices around mocking are completely unknown, misunderstood, or ignored. Developers who use mocks and patches without doing TDD or OOD are susceptible to falling into many well-understood and documented traps.
This talk will draw a historical connection between the way mocks are taught today, and their origins in TDD, OOD, and Java. It will also demonstrate some pitfalls, and provide some guidance and alternatives to mocking and patching (e.g., dependency injection, test doubles, functional style).
Slides can be found at: speakerdeck.com/pycon2019 and github.com/PyCon/2019-slides"

Опубликовано:

 

4 май 2019

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 11   
@ericsalesdeandrade9420
@ericsalesdeandrade9420 19 дней назад
Excellent talk and very helpful to see good patterns in practice.
@taylorbird901
@taylorbird901 3 года назад
Wish this had come up as the first result. Lots of other vids are having conceptual feuds about tdd so conversation becomes more about definitions of terms and avoiding dogma instead of answering the question "how do I use this to write better software?" Even searching for discussions by Beck, Fowler Martin etc and those who came up with and named some of the principles results in talks that presume prior knowledge in the audience or are speaking to broader architecture concerns moreso than practical implications much of the time, which is understandable given their depth of experience and how much they have to speak to these topics and must want to move on and innovate rather that rehash, but that leaves a niche for people trying the techniques and running into walls which this talk addresses perfectly. This talk does a great job with visuals and points to all the worthwhile source material for further reference. Really valuable stuff.
@RoamingAdhocrat
@RoamingAdhocrat Год назад
yeah, I keep coming back to this video, and keep forgetting what to search for to find it…
@thanhtan030t
@thanhtan030t Год назад
@@RoamingAdhocrat Same here : v
@alexanderzveruk1234
@alexanderzveruk1234 5 лет назад
Brilliant, mind changing
@yuryg.
@yuryg. 11 месяцев назад
nice talk!
@seerozhaa2656
@seerozhaa2656 Год назад
thanks, really interesting talk!
@danilkister1650
@danilkister1650 3 года назад
I APPROVE.
@blackswan2020
@blackswan2020 2 года назад
Audio is a little too quiet!
@xjazz666
@xjazz666 3 года назад
Mock =! Stub ... Ok thanks. Let's review my code then ....
Далее
Mocking Strategies in Python
43:42
Просмотров 32 тыс.
Talk: Harry Percival - Stop Using Mocks (for a while)
44:51
🚀  TDD, Where Did It All Go Wrong (Ian Cooper)
1:03:55
Просмотров 556 тыс.