Skip to content

Latest commit

 

History

History
38 lines (25 loc) · 2.1 KB

README.md

File metadata and controls

38 lines (25 loc) · 2.1 KB

BugsZero Kata

Bugs are optional, they sneak into our code much thanks the design choices we do, or fail to do. Let's try refactoring some existing code to make it more bug-repellent!

You'll practice reading code, looking for parts where it is likely that a developer would create a bug if he extended the code. Whenever you've found such a weakness in the design your challenge is to strengthen the design in order to make that kind of bug very unlikely, or even impossible!

First Identify a weakness in the design. Then State what the potential bug is before explaining your solution. This is important, simply saying another solution is better avoids thinking of why it is actually better. Finally Explain or refactor the code to show the new design.

Where do I start?

Beginner

Make sure you know of a few ways to design away bugs, by looking at a few examples

Have a look at the long list of common bug-patterns, mostly unnecessary weaknesses in design. Beware, those are a bit terse, most patterns need to be explained.

Intermediate

We've found some weaknesses for you. Pick your choice in instructions-intermediate.md

Advanced

If you'e already accustomed this thinking this way, have a look at instructions-advanced.md

Next steps

Go use this on some other code base, like your project!

Give us some suggestions in the issues.

Resources on #BugsZero

Some slides specifically on code design

The general part 15 min intro or go for the full presentation