The code I see from people is often buggy as hell. How the hell is code so buggy? Do people not bugtest their software before release? How do you test your code for bugs? Do you use any third-party software like softice?
It depends a LOT on the type of program, and the language and tools available for it.
Delphi has a very nice integrated debugger, so setting break points and watches can be very helpful.
For small functions, I will do test cases, including trying to find the boundary conditions and test the behavior for them.
I do debugging output statements on a regular basis.
When processing large amounts of data, I use extensive exception handling and log errors to file with as many details as I can get.
I typically break my programs down by function/class and test them individually while creating the program, then do an overall test of the program once it's compiled.
One method for testing is Test Driven Development (TDD) although I don't use this method. Using Unit Testing also helps. Aside from that, running the program yourself and having users test it for bugs is vital because they will do things you don't expect or intend.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks