3
r0bb
4y

Can someone explain tests to me? Maybe I'm a little behind but like, don't you test your code when you run it? Why do you have to write tests instead of just running the code you wrote and testing that?

Comments
  • 5
    Automated testing means repeatability and verifiable lack of regressions when changes are made. It also means a provable record of delivered functionality.
  • 7
    Because if you cannot run tests automatically, you have to test each functionality manually. Or you deploy an undefined software package with potential bugs. You will not know. I know the feeling of deploying that way. It isn't fun. And now, I have application were thousands of assertions run on each build. I know that the software will work in those cases! Clicking through a shop process once is a pain. Doing it everytime you add a feature is ludricious. Especially as the application grows in features you have to increase your test cases. As you can never be sure that you did not break something in your application when coding. Just running the code and test it implies you only need it once. It couldn't be further from the truth. You *always* want to know that your code does what it should do. It still will have bugs, yet once they are found, you can write tests for those cases as well.
  • 0
    @k0pernikus accurate, good explanation
  • 0
    @k0pernikus great explanation, thank you v so much
  • 3
    Your question triggered a rant about working in a company not wanting software with tests: https://www.devrant.io/rants/320838
Add Comment