Feb 3rd, 2019
26. Testing, Attention Please!
If you can't test it, don't bother building it.
We're developers but we're also humans, we're going to make mistakes. We make assumptions as we write our code. We think it's going to do something, often times it doesn't. It's really important that you test your assumptions at every level.
Manual testing is fine but you can't rely solely on it. As you write tests you'll see that some of your assumptions were incorrect. You'll see that some things take way longer than you want them to, you'll see that in different edge cases weird things are getting returned.
Testing isn't any different from writing code. It's the same. You're writing code to test the code that you wrote. That's all it is.
Pick one of the functions that you have, try to test it. If you can't test it, it probably means it's a sh*ty function and you should rewrite it.
About the Guest
- Richard is a software engineer/ software development engineer in test at InRhythm, where he helps other software engineers right quality code.
- He is a blockchain enthusiast and is teaching himself Solidity, a programming language for implementing smart contracts, while working on his own blockchain project.
- He doesn’t drink, but made an exception for The Drunk Web.