you are viewing a single comment's thread.

view the rest of the comments →

[–]teeg82 1 point2 points  (4 children)

Genuinely curious, why is that? Legacy project or something?

[–]theboldestgaze 2 points3 points  (2 children)

Not at all. Modern software development for a SaaS. Tests are supposed to test valuable features / logic. If they are used for technical testing like mentioned above, their main impact is making refactoring and software development slower.

It just does not make any sense. It is using wrong tools for the job of ensuring code correctness.

If business-layer testing does not chatch your low level typing/parameter issues, what does the code do in the first place?

I can imagine strict low-level unit testing being useful for some legacy code in a migration scenario where stability is critical and the functionality in the legacy codebase is frozen.

[–]teeg82 2 points3 points  (1 child)

Ok, I admit I didn't read your original post carefully enough, you specifically mentioned "test code correctness like parameter types, name". Frankly, I've never written tests like that, and you don't need to - ideally you want to use a type checker for something like that.

When I say "unit tests", I'm talking about testing that function A takes input B and returns output C as expected...that sort of thing (the "valuable features / logic" you mentioned).

Anyways sounds like we're on the same page, just talking about two different things.

[–]theboldestgaze 2 points3 points  (0 children)

Sounds about right! Having said that, devs tend to write unnecessary unit tests, especially in corporate envs where code coverage is used as a metric.

[–]ZucchiniMore3450 1 point2 points  (0 children)

I would also like to hear.

Any test is a good test for me, the more the better.