Viceroy icon indicating copy to clipboard operation
Viceroy copied to clipboard

Support for test coverage

Open lfdominguez-bhn opened this issue 9 months ago • 2 comments

Is planned the support for coverage generation?

lfdominguez-bhn avatar Apr 08 '25 20:04 lfdominguez-bhn

@lfdominguez-bhn Can you provide some more information on your use case. Are you looking to be able to get coverage results from your unit tests running within Viceroy? What is your target language?

posborne avatar Apr 23 '25 20:04 posborne

Yes, my target language is Rust. I'm using cargo nextest run with the viceroy test mode, and it's working okay. But of course, the runtime in this case needs to support instrumentation on code to output coverage data (like .profraw and .gcda) to use another tool, like grcov, to visualize the generated coverage information.

In this case we can't use llvm tools because the target is wasm-wasip1 and by itself not run, is viceroy who run it. Like I see viceroy it's based on wasmtime and this issue exists with some ideas to implement it:

https://github.com/bytecodealliance/wasmtime/issues/1151

lfdominguez-bhn avatar Apr 24 '25 14:04 lfdominguez-bhn