How To Create A Factory Pytest Fixture (Testing Python With Pytest)

preview_player
Показать описание
This video goes over a basic factory pattern you can use in your pytest fixtures to generate dynamic setup variables.

It covers generating a `Person` object, each time with a unique name while still allowing easy customization when needed.

You can also find me on:
Рекомендации по теме
Комментарии
Автор

The idea of using a factory function to turn the fixture more dynamic was amazing, Thx very much.

alexemanoel
Автор

Dam this was too advanced for me

Cameron can we get a rookie video for this?

chriskeo
Автор

Hi Cameron, great series !
If i got my understanding right - Line 18 calls the method to iterate over people created in a list in Line 14-17.

Question:
Could you explain why the Line 6 person method has a nested method ?
Could you not have just the one method alone? I kind of lost track there.

Thanks

manojmurali
welcome to shbcf.ru