Thread overview
Re: Cumulative code coverage?
Mar 21, 2018
H. S. Teoh
Mar 21, 2018
H. S. Teoh
Mar 22, 2018
H. S. Teoh
March 21, 2018
On Wed, Mar 21, 2018 at 05:34:58PM +0000, Seb via Digitalmars-d wrote:
> On Wednesday, 21 March 2018 at 16:39:48 UTC, H. S. Teoh wrote:
> > Is it possible to get cumulative code coverage using dmd? I.e., accumulate code coverage stats over a series of runs from an external test suite.
[...]
> Yes, either set dmd_coverSetMerge(true) or pass --DRT-covopt "merge:1"
> to your program.
[...]

Cool, passing --DRT-covopt="merge:1" did the trick.

Thanks!


T

-- 
Bare foot: (n.) A device for locating thumb tacks on the floor.
March 21, 2018
On Wed, Mar 21, 2018 at 12:35:08PM -0700, H. S. Teoh via Digitalmars-d wrote: [...]
> Cool, passing --DRT-covopt="merge:1" did the trick.
[...]

Speaking of which, are the --DRT-* options documented anywhere?? I don't even know where to begin to look, besides in the druntime code itself.


T

-- 
Unix was not designed to stop people from doing stupid things, because that would also stop them from doing clever things. -- Doug Gwyn
March 22, 2018
On Wednesday, 21 March 2018 at 19:44:19 UTC, H. S. Teoh wrote:
> On Wed, Mar 21, 2018 at 12:35:08PM -0700, H. S. Teoh via Digitalmars-d wrote: [...]
>> Cool, passing --DRT-covopt="merge:1" did the trick.
> [...]
>
> Speaking of which, are the --DRT-* options documented anywhere?? I don't even know where to begin to look, besides in the druntime code itself.
>
>
> T

I think you're looking for: "Controlling the Coverage Analyser" under https://dlang.org/articles/code_coverage.html.
March 22, 2018
On Thu, Mar 22, 2018 at 06:31:21AM +0000, Petar via Digitalmars-d wrote:
> On Wednesday, 21 March 2018 at 19:44:19 UTC, H. S. Teoh wrote:
> > On Wed, Mar 21, 2018 at 12:35:08PM -0700, H. S. Teoh via Digitalmars-d wrote: [...]
> > > Cool, passing --DRT-covopt="merge:1" did the trick.
> > [...]
> > 
> > Speaking of which, are the --DRT-* options documented anywhere?? I don't even know where to begin to look, besides in the druntime code itself.
[...]
> I think you're looking for: "Controlling the Coverage Analyser" under https://dlang.org/articles/code_coverage.html.

Ah, thanks!  That's exactly what I was looking for.

Still, it would be nice to have a list of all --DRT-* options (not necessarily related to coverage) somewhere, just for reference.


T

-- 
If you want to solve a problem, you need to address its root cause, not just its symptoms. Otherwise it's like treating cancer with Tylenol...