Code smell
Code smell in the source code is any indication on the surface of the programming code that hints at a deeper problem. This can be as trivial as an oversized method. The most accurate indication of a code smell is the testability of the code. If the code can be tested in a very simple and straightforward test then that means the code is not tightly coupled. This also means that the code is doing only one task, which can be tested end to end.
"a code smell is a surface indication that usually corresponds to a deeper problem in the system" | ||
--Martin Fowler |
There are a few types of code smell that can be identified by looking at the code.
Expendable
An expendable is something gratuitous and futile. Removal of such code will make the code ...
Get Scala Test-Driven Development now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.