cairo/.gitlab-ci/build-with-coverage.sh
Federico Mena Quintero 744f4d75b3 CI: Add a basic test coverage job
Later we'll add one coverage job per backend, and aggregate all of the
results at the end for the coverage report.
2024-08-27 21:18:10 -06:00

17 lines
533 B
Bash

#!/bin/sh
set -eux -o pipefail
export CFLAGS="-coverage -ftest-coverage -fprofile-arcs"
export CAIRO_TEST_IGNORE_image_argb32=$(tr '\n' ',' < .gitlab-ci/ignore-image-argb32.txt)
export CAIRO_TEST_IGNORE_image_rgb24=$(tr '\n' ',' < .gitlab-ci/ignore-image-rgb24.txt)
export CAIRO_TEST_IGNORE_image16_rgb24=$(tr '\n' ',' < .gitlab-ci/ignore-image16-rgb24.txt)
export CAIRO_TEST_TARGET=image,image16
meson setup --buildtype=debug _build .
meson compile -C _build
export srcdir=../../test
cd _build/test
xvfb-run ./cairo-test-suite