test: ignore inconsistent coverage errors
authorFrantisek Sumsal <frantisek@sumsal.cz>
Fri, 15 Nov 2024 13:31:53 +0000 (14:31 +0100)
committerLuca Boccassi <luca.boccassi@gmail.com>
Fri, 15 Nov 2024 15:54:28 +0000 (15:54 +0000)
commit238ddac1653fd94d402d97475d627374cd89ed8e
tree1ddeba41958c1defe101cc5d023df64ae8630f22
parentbe6e599935cd5206d830e6337881031308e890e2
test: ignore inconsistent coverage errors

lcov 2.1 introduced additional consistency checks [0] which make it trip
over our coverage results quite often:

Summary coverage rate:
  source files: 915
  lines.......: 36.9% (78950 of 214010 lines)
  functions...: 53.3% (6906 of 12949 functions)
Message summary:
  73 warning messages:
    inconsistent: 73
lcov: ERROR: (corrupt) unable to read trace file '/var/tmp/systemd-test-TEST-04-JOURNAL/coverage-info.new': lcov: ERROR: (inconsistent) "/build/src/shutdown/umount.c":298: function 'umount_with_timeout' is not hit but line 317 is.
        To skip consistency checks, see the 'check_data_consistency' section in man lcovrc(5).
        (use "lcov --ignore-errors inconsistent ..." to bypass this error)
        (use "lcov --ignore-errors corrupt ..." to bypass this error)

This is caused by coverage collected during shutdown which is a bit
unreliable, especially towards the final shutdown stage(s). Let's just
ignore the consistency errors for now.

[0] https://github.com/linux-test-project/lcov/releases/tag/v2.2
test/test-functions