DEV Community

Discussion on: Should bugs be discovered in a code review?

Collapse
 
dmfay profile image
Dian Fay

If it does the wrong thing it doesn't matter how elegant it is. Of course reviewers should consider correctness a criterion for approval. That doesn't mean whiteboarding flowcharts or inspecting every conditional with a microscope. Tests help with this but don't achieve it on their own: a test documents the intent of the code, not that the intent matches the requirement.