Skip to content
Snippets Groups Projects
Commit f6ff85b1 authored by Pekka Paalanen's avatar Pekka Paalanen
Browse files

CI: work around Gitlab Cobertura parsing quirk

This should not be necessary, but my testing with fd.o Gitlab 13.9.1
shows this is needed. Otherwise the coverage markings will not appear in
a MR diff view.

Apparently Gitlab has some problem with 'filename' attribute containing
"../" in Cobertura XML files, even when that does result in a correct
path. Or maybe the problem is is with the <source> path referring to the
build dir which from Gitlab perspective does not exist in the project,
even though builddir/../ is a good path.

This sed hack removes the "../" part and the last element in the
<source> path correspondingly.

See wayland/weston!567


for my testing.

Signed-off-by: default avatarPekka Paalanen <pekka.paalanen@collabora.com>
parent e72119f1
No related branches found
No related tags found
No related merge requests found
......@@ -109,6 +109,7 @@ build-native-meson-default-options:
after_script:
- ninja -C build-* coverage-html
- ninja -C build-* coverage-xml
- sed -i -e 's/\/build-weston-build-native-meson-default-options//' -e 's/\"..\//\"/' build-*/meson-logs/coverage.xml
artifacts:
reports:
cobertura: build-*/meson-logs/coverage.xml
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment