digitalmars.D.learn - Code-coverage
- Sai (5/5) Dec 05 2005 My source files are spread in directories in java style. How can I do co...
- James Dunne (4/14) Dec 05 2005 Hope you're not jumping the gun, but the .lst files are generated when
- clayasaurus (3/13) Dec 05 2005 Yea, there should only be 1 .lst file created for your program. Compile
- clayasaurus (4/20) Dec 05 2005 Nevermind. My advice is to use build with the -cov option, then after
- sai (8/13) Dec 16 2005 Now I understand, why no .lst files were created for my program.
- Sean Kelly (4/11) Dec 16 2005 Nothing official, though you could try this:
My source files are spread in directories in java style. How can I do code coverage for all sources ? with just -cov option, no .lst files are created. Thanks in advance Sai
Dec 05 2005
Sai wrote:My source files are spread in directories in java style. How can I do code coverage for all sources ? with just -cov option, no .lst files are created. Thanks in advance SaiHope you're not jumping the gun, but the .lst files are generated when the program is run. I haven't tried a multi-directory style D app with -cov, but it works with a single-directory app.
Dec 05 2005
Sai wrote:My source files are spread in directories in java style. How can I do code coverage for all sources ? with just -cov option, no .lst files are created. Thanks in advance SaiYea, there should only be 1 .lst file created for your program. Compile your D program to an exe, then run 'dmd my.exe -cov'
Dec 05 2005
clayasaurus wrote:Sai wrote:Nevermind. My advice is to use build with the -cov option, then after you run your exe the .lst file should be created. Although in the bugs forum it looks like someone is having trouble with it.My source files are spread in directories in java style. How can I do code coverage for all sources ? with just -cov option, no .lst files are created. Thanks in advance SaiYea, there should only be 1 .lst file created for your program. Compile your D program to an exe, then run 'dmd my.exe -cov'
Dec 05 2005
Now I understand, why no .lst files were created for my program. I was always exiting using std.c.stdlib.exit(0); which wasn't exiting cleanly. Today by mistake, due to an exception, when the program exited through return in "main", all .lst files were created ! Is there any clean way of exiting (or aborting) in D ? Thanks in advance Sai In article <dn2dur$2bur$1 digitaldaemon.com>, Sai says...My source files are spread in directories in java style. How can I do code coverage for all sources ? with just -cov option, no .lst files are created. Thanks in advance Sai
Dec 16 2005
sai wrote:Now I understand, why no .lst files were created for my program. I was always exiting using std.c.stdlib.exit(0); which wasn't exiting cleanly. Today by mistake, due to an exception, when the program exited through return in "main", all .lst files were created ! Is there any clean way of exiting (or aborting) in D ?Nothing official, though you could try this: throw new Exception("Terminate called."); Sean
Dec 16 2005