0

Hi I want to calculate my coverage using kcov (for rust) but when I run the following:

kcov target/cov target/debug/foo-9685a754b64cd612

Kcov right the result in target/cov but it never return and I am having to kill the prosses with signal segfault (C-c is not working for some reason).

this behaviour only happens with my project to; I cloned another project and it finishes correctly.

How do i stop this madness?

julia
  • 139
  • 3
  • 11
  • We're lacking some information, there. I guess that some of your test is in fault: does your `cargo test` hang also? – Boiethios Feb 07 '20 at 10:15
  • no my test is just an assert_eq(true, true) to test coverage and cargo test execute fine – julia Feb 07 '20 at 10:19
  • I don't see what we can do to help you. – Stargateur Feb 07 '20 at 10:20
  • thank you for trying at least – julia Feb 07 '20 at 10:21
  • _no my test is just an assert_eq(true, true)_ Just a guess: do you use `export RUSTFLAGS='-C link-dead-code'` maybe it can't find any code to check coverage ( you need to set this flag before `cargo test`) – Ömer Erden Feb 07 '20 at 10:21
  • @ÖmerErden i did not but now (`RUSTFLAGS='-C link-dead-code' cargo test --no-run`) it doesn't even run the test – julia Feb 07 '20 at 10:49
  • Please follow: https://pastebin.com/Qr9FXvGr – Ömer Erden Feb 07 '20 at 13:26
  • I'm sorry but it did not change the outcome (i checked several times that the variable is set correctly) kcov is never running the test when rustflags='-C link-dead-code' is set – julia Feb 07 '20 at 14:05

0 Answers0