Comment by zingar

17 hours ago

Without arguing with your main point:

> (few people like writing unit tests)

The TDD community loves tests and finds writing code without tests more painful than writing tests before code.

Is your point that the TDD community is a minority?

> It does a better job at writing unit test (not perfect) then the fellow human programmer

I see a lot of very confused tests out of cursor etc that do not understand nor communicate intent. Far below the minimum for a decent human programmer.

I see tests as more of a test of the programmer's understanding of their project than anything. If you deeply understand the project requirements, API surface, failure modes, etc. you will write tests that enforce correct behaviour. If you don't really understand the project, your tests will likely not catch all regressions.

AI can write good test boilerplate, but it cannot understand your project for you. If you just tell it to write tests for some code, it will likely fail you. If you use it to scaffold out mocks or test data or boilerplate code for tests which you already know need to exist, it's fantastic.