473,505 Members | 14,950 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

code coverage tool with emacs integration?

Anybody know of one?

Actually, I have a feeling that emacs understands a standard format
for errors, which would make it really easy to implement this by
having the coverage tool print results in that format -- anybody know
where to find the details?
I also wonder if some kind of graphical display might be useful
somehow, having been inspired by this:

http://kcachegrind.sourceforge.net/

(really, I just like the pretty pictures :)
John
Jul 18 '05 #1
3 2768

John> Anybody know of one?

John> Actually, I have a feeling that emacs understands a standard
John> format for errors, which would make it really easy to implement
John> this by having the coverage tool print results in that format --
John> anybody know where to find the details?

compilation-error-regexp-alist. The simplest format to remember is

filename:linenumber:message

I'm not sure what you're after though. Code coverage tools generally emit
annotated listings, not compiler-like output. What would you like it to do,
emit file:line:msg info for the start of each run of lines which weren't
covered? How would you get any context showing you what lines in the region
had been executed at least once?

Skip

Jul 18 '05 #2
Skip Montanaro <sk**@pobox.com> writes:
[...]
compilation-error-regexp-alist. The simplest format to remember is
Thanks.

[...] emit file:line:msg info for the start of each run of lines which weren't
covered?
Yes.

How would you get any context showing you what lines in the region
had been executed at least once?


Why would I want to?

I haven't done any proper code-coverage analysis before, but I
had imagined just doing:

while 1:
uncovered = run_coverage_tool(my_code)
if not uncovered: break
jump_to(uncovered[0])
think()
write_test()
John
Jul 18 '05 #3
How would you get any context showing you what lines in the region
had been executed at least once?


John> Why would I want to?

For me, analyzing code coverage consists of studying the code in the region
around the uncovered line(s). Knowing which lines in the area have and
haven't been covered helps me analyze what's missing in my test coverage.

Skip

Jul 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

50
5433
by: Edward K. Ream | last post by:
I would like to say a few (actually more than a few) words here about some recent discoveries I have made concerning the interaction of Leo and Python. If you don't want to hear an inventor enthuse...
49
4067
IDE
by: Thomas Lindgaard | last post by:
Hello I am probably going to start a war now... but so be it :) I just want to hear what all you guys who eat pythons for breakfast use for python coding. Currently I use Kate, but I would...
6
2355
by: tjm | last post by:
Pure coverage from Rational is the only coverage tool I've been able to find for C#, and I don't really want to pay what Rational charges for something as simple as a coverage tool. So, I'd like...
10
2528
by: Olaf Wasmuth | last post by:
Good morning, I am using doxygen to create a reference manual for C source code. Do you know of a way to similarly create a texinfo reference manual (which I would like to use in emacs...
5
4854
by: Nikhil | last post by:
Hi, I have a set of C source files and I need a tool which can add probes and then dynamically trace the execution and print the results (The C source code does not have any printf statements)....
1
2016
by: =?UTF-8?B?TWFydGluIFDDtnBwaW5n?= | last post by:
Hello, I am searching for a good profiling tool for C# which can be easily embedded into Visual Studio. My objective is to measure the times and counts of every method in my program. If...
4
4371
by: Richard Szopa | last post by:
Hi All, I am a devoted Emacs user and I write a lot in Python. However, I never managed to get my Emacs configuration right for this purpose. There were some discussions on this, but the threads...
5
4266
by: ev | last post by:
Hello, We are looking for any testing tool that is capable of checking code coverage for C,C ++ and Java code. Or at least for C and C++. We want to know how much (percentage) of our code written...
24
2485
by: David | last post by:
Hi list. What strategies do you use to ensure correctness of new code? Specifically, if you've just written 100 new lines of Python code, then: 1) How do you test the new code? 2) How do...
0
7216
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7098
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7303
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7367
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7018
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7471
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5613
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3176
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1528
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.