3 ms·
I almost never write test beforehand, unless I'm working on a really complex subject, where I need to write all tests first to grasp the problem entirely. Other
by littlestymaar 7y ago
I almost never write test beforehand, unless I'm working on a really complex subject, where I need to write all tests first to grasp the problem entirely. Otherwise, I write tests before submitting the pull request.
I almost never write tests for personal projects, but 100% of the time when working in a team. IMO, tests are not here to prevent bugs, but they are part of the developer documentation: a coworker must be able to make any change they want to my code without asking me anything, and tests are the biggest part of that.