No description
- Python 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| .gitignore | ||
| paint.py | ||
| README.md | ||
| test_paint.py | ||
Paint3000 - a refactoring exercise
Instructions
First, make sure you can run the tests. This will involve creating a virtualenv and installing pytest in it.
Second, try and understand what the Paint class does and how it works.
Then, try to use the Command/Query separation and the Single Responsibility principles to refactor the code.
Notes:
- You must not change the public API of the
Paintclass nor the./test_paint.pyfile - You can introduce as many classes and as many modules you want.
Have fun :)
Credits
Code adapted from the "Clean Code In the Browser" series, by Chris Powers.