Loading…
Attending this event?
Back To Schedule
Thursday, June 8 • 10:30 - 15:30
Dirty Tests and How To Clean Them

Sign up or log in to save this to your schedule, view media, leave feedback and see who's attending!

We write tests and code for other people. Tests are code too, and both types should be clean.
As a clean code fanatic, I see it as a personal mission to go around preaching how powerful clean code is. But unfortunately, it seems that test code is not considered "real code", and therefore is not considered "dirty".

In this workshop, we'll discuss concrete examples of anti-patterns in test code, and how to clean them up. We'll then refactor prepared examples into proper code, based on clean code principles, in different cases - like APIs to end-to-end. We'll deal with the following:

- Removing duplications
- Naming effectively
- Using fixtures for common code
- Apply the page-object model and builder patterns
- Use literals and constant correctly
- Abstract low-level and framework code

"Clean code looks like it was written by someone who cares.", said Michael Feathers. Test code may even be more important to write cleanly for that reason.

Key takeaways:
​- What makes code clean
- How do clean code principles apply to tests
- Anti-pattern in tests and how to fix them
- Refactoring techniques

Speakers
avatar for Gil Zilberfeld

Gil Zilberfeld

CTO, TestinGil
Gil Zilberfeld (TestinGil) has been in software since childhood, writing BASIC programs on his trusty Sinclair ZX81. With more than 25 years of developing commercial software, he has vast experience in software methodology and practices. Gil has been teaching and applying modern... Read More →


Thursday June 8, 2023 10:30 - 15:30 EEST
Stalker
Feedback form isn't open yet.