News for hackers. Stuff that matters.
Re:Changing how I review code by all2 on Wednesday June 30, 2021 @05:49PM (#27693785)
Just because there are tests doesn't mean the tests are any good. I've only started my quest in TDD and I've discovered it is rather trivial to write tests that don't really mean anything.

I find myself asking "what is this supposed to do?" and "does this actually do what it is supposed to do?". I tend to drift into a design mindset during test writing (more-so than in code review) that highlights data flow and the basic bits of logic. Even then, I find that I can miss test cases rather easily.

Re:Changing how I review code by jimbobimbo on Wednesday June 30, 2021 @06:44PM (#27694379)
That's what code coverage tooling + human code reviewers are for. Look at the change in product, look at the amount of changes in tests - do they make sense? E.g., product change adds a non-trivial function with 10 if/else branches, but UTs touch only happy path - that's a legitimate blocker on the PR.