3 ms·
None of any of that applies to the point at which he was writing the test, and all of it would be covered by the integration tests he says he writes. I have se
by jdminhbg 11y ago
None of any of that applies to the point at which he was writing the test, and all of it would be covered by the integration tests he says he writes.
I have seen some truly awful, pointless, tightly-coupled controller tests (testing if an instance variable is assigned, for example) in my career. If there's enough logic in a controller that testing it at a level lower than a general acceptance/integration test is useful, it should almost certainly be in a model or a service object.
- 746F7475 11y agoImo you always need to test error cases with web sites and apis specially. It's just stupid that some API returns "200: OK", {"result": {"error": "result not found"}}. But I guess this is mainly about point of view. I used to be a developer, but now I'm employed full time as tester, so I have very different views on what needs to be tested than developers I know.