Abstract
How do you know that your program works? Can you rely on yourself to write flawless code all the time? Meaning no disrespect, I would guess that’s unlikely. It’s quite easy to write correct code in Python most of the time, certainly, but chances are your code will have bugs.1 Debugging is a fact of life for programmers—an integral part of the craft of programming. However, the only way to get started debugging is to run your program. Right? And simply running your program might not be enough. If you have written a program that processes files in some way, for example, you will need some files to run it on. Or if you have written a utility library with mathematical functions, you will need to supply those functions with parameters in order to get your code to run.
Did you know that the original computer bug was, in fact, a moth? It was found stuck in a relay in the Mark II computer at Harvard in 1945. The term bug for a computer glitch and the related word debugging are credited to Grace Hopper, who taped the original bug into her logbook. The logbook—with the bug—is on display at the US Naval Surface Weapons Center in Dahlgren, Virginia. (See http://en.wikipedia.org/wiki/Software_bug for more information.)
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Rights and permissions
Copyright information
© 2008 Magnus Lie Hetland
About this chapter
Cite this chapter
Hetland, M.L. (2008). Testing, 1-2-3. In: Beginning Python. Apress. https://doi.org/10.1007/978-1-4302-0634-7_16
Download citation
DOI: https://doi.org/10.1007/978-1-4302-0634-7_16
Publisher Name: Apress
Print ISBN: 978-1-59059-982-2
Online ISBN: 978-1-4302-0634-7
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)