| |||||
Technical Support Support Resources
Product Information | DSCOPE: CODE COVERAGE AND TEST SCRIPTSQUESTIONIs it possible to run code coverage from a dScope script file? I need to print out the code coverage information as part of an automated test. ANSWERCode Coverage automatically runs whenever your program executes in dScope. Unfortunately, there is no way to automatically print out the code coverage information. Nonetheless, the following may help. You may create or append to a log file using the following command: log >> filename You can include this command in a dScope script file. After your program runs for awhile, you may select the starting and ending lines of parts of your program (in the Module Window) and write that to the file. However, you must use the mouse to do that. You may want to try the macro recorder built into Windows to automate this part. As an alternative, you may set breakpoints at specific locations in your code. When the breakpoint is executed, you can instruct dScope to printf a message and continue execution. Everything that is printed appears in the Command Window and gets sent to the Log file. Last Reviewed: Monday, June 07, 2004 | ||||
| |||||