Testing and Debugging Applications
Testing involves finding problems in your code; debugging consists of isolating and fixing the problems. Testing and debugging are necessary stages in the development cycle, and they are best incorporated early in the cycle. Thoroughly testing and debugging individual components makes testing and debugging integrated applications much easier.
Typically, developers look for different levels of robustness as they are testing and debugging their applications:
- Running without crashing or generating error messages.
- Appropriate action in common scenarios.
- Reasonable action or error messages in a range of scenarios.
- Graceful recovery from unexpected user interactions.
Visual FoxPro provides a rich set of tools to help you isolate and identify the problems in your code so that you can fix them effectively. However, one of the best ways to create a robust application is to look for potential problems before they occur.
In This Section
- Creating Bookmarks and Task List Shortcuts
Use bookmarks and shortcuts in the Editor to easily step through your code. - Testing a Project
Verify your application before the final build. - Handling Run-Time Errors
Run-time errors can occur after the application starts to execute. - Debugging Before Bugs Exist
Studies have shown that good coding practices (using white space, including comments, adhering to naming conventions, and so on) automatically tend to reduce the number of bugs in your code. - Isolating Problems
When your testing has identified problems, you can use the Visual FoxPro debugging environment to isolate those problems.
Related Sections
- Coverage Profiler Application
During the development process, you might want to refine your code for performance and make sure you have adequately tested the code by logging code coverage information. - Using the Automated Test Harness
Use the Automated Test Harness to record and play back automated test scripts to verify application behavior. - Compiling an Application
Create your applications one piece at a time, verifying each component as you go. When all your components are in place, it is easy to compile them into an application. - Optimizing Applications
When you have a stable, running application, consider ways to optimize its performance by making your application smaller and faster. - Using Visual FoxPro
Visual FoxPro programming features are designed to improve developer productivity, including Access and Assign methods, support for more graphic file formats, and language to simplify programming tasks. - Developing Visual FoxPro Applications
This section includes conceptual information about how to develop Visual FoxPro applications, instructions for creating databases and the user interface, and other tasks needed to create Visual FoxPro applications.