[glib/3v1n0/allocation-benchmarks: 1/2] CI: run benchmarks instead of tests
- From: Marco Trevisan <marcotrevi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib/3v1n0/allocation-benchmarks: 1/2] CI: run benchmarks instead of tests
- Date: Fri, 8 Jul 2022 22:21:49 +0000 (UTC)
commit c46678dfd4da9e9b6ff77a3f4767e1770c443900
Author: Marco Trevisan (TreviƱo) <mail 3v1n0 net>
Date: Thu Jul 7 16:47:24 2022 +0200
CI: run benchmarks instead of tests
.gitlab-ci.yml | 26 ++++----------------------
.gitlab-ci/run-tests.sh | 1 +
.gitlab-ci/test-msvc.bat | 2 +-
.gitlab-ci/test-msys2.sh | 18 ++----------------
4 files changed, 8 insertions(+), 39 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 8fe839a758..c8dd3c4d38 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -68,7 +68,7 @@ fedora-x86_64:
stage: build
needs: []
variables:
- CFLAGS: "-coverage -ftest-coverage -fprofile-arcs"
+ CFLAGS: "-fprofile-arcs"
script:
- meson ${MESON_COMMON_OPTIONS}
--werror
@@ -79,13 +79,9 @@ fedora-x86_64:
-Dsystemtap=true
-Ddtrace=true
-Dinstalled_tests=true
- -Dgtk_doc=true
_build
- ninja -C _build
- - mkdir -p _coverage
- - lcov --config-file .lcovrc --directory _build --capture --initial --output-file
"_coverage/${CI_JOB_NAME}-baseline.lcov"
- .gitlab-ci/run-tests.sh
- - lcov --config-file .lcovrc --directory _build --capture --output-file "_coverage/${CI_JOB_NAME}.lcov"
artifacts:
reports:
junit: "_build/meson-logs/testlog.junit.xml"
@@ -261,6 +257,7 @@ cross-android_arm64:
# FIXME: add --werror
- meson ${MESON_COMMON_OPTIONS} --cross-file=.gitlab-ci/cross_file_android_arm64_31.txt _build
- ninja -C _build
+ - meson test -C _build --benchmark -v --timeout-multiplier 10
cross-mingw64:
extends:
@@ -271,6 +268,7 @@ cross-mingw64:
# FIXME: Add --werror
- meson ${MESON_COMMON_OPTIONS} --cross-file=/opt/cross_file_mingw64.txt _build
- ninja -C _build
+ - meson test -C _build --benchmark -v --timeout-multiplier 10
artifacts:
reports:
junit: "_build/meson-logs/testlog.junit.xml"
@@ -465,22 +463,6 @@ macos:
- "_build/glib/glibconfig.h"
- "_build/meson-logs"
-coverage:
- extends: .only-default
- image: $FEDORA_IMAGE
- stage: coverage
- needs: ['fedora-x86_64', 'msys2-mingw32']
- artifacts:
- name: "glib-${CI_JOB_NAME}-${CI_COMMIT_REF_NAME}"
- expire_in: 1 week
- paths:
- - _coverage/
- before_script:
- - bash .gitlab-ci/show-execution-environment.sh
- script:
- - bash -x ./.gitlab-ci/coverage-docker.sh
- coverage: '/^\s+lines\.+:\s+([\d.]+\%)\s+/'
-
scan-build:
extends:
- .build-linux
@@ -545,7 +527,7 @@ pages:
stage: deploy
only:
- main
- needs: ['coverage', 'style-check-diff']
+ needs: ['style-check-diff']
script:
- mv _coverage/ public/
artifacts:
diff --git a/.gitlab-ci/run-tests.sh b/.gitlab-ci/run-tests.sh
index 86402dcaf4..441e015a1b 100755
--- a/.gitlab-ci/run-tests.sh
+++ b/.gitlab-ci/run-tests.sh
@@ -2,6 +2,7 @@
meson test \
-C _build \
+ --benchmark -v \
--timeout-multiplier "${MESON_TEST_TIMEOUT_MULTIPLIER}" \
--no-suite flaky \
"$@"
diff --git a/.gitlab-ci/test-msvc.bat b/.gitlab-ci/test-msvc.bat
index 37976d4d00..ccee8c8322 100644
--- a/.gitlab-ci/test-msvc.bat
+++ b/.gitlab-ci/test-msvc.bat
@@ -17,7 +17,7 @@ meson %args% _build || goto :error
ninja -C _build || goto :error
:: FIXME: dont ignore test errors
-meson test -C _build --timeout-multiplier %MESON_TEST_TIMEOUT_MULTIPLIER% --no-suite flaky
+meson test -C _build --benchmark -v --timeout-multiplier %MESON_TEST_TIMEOUT_MULTIPLIER% --no-suite flaky
:: FIXME: can we get code coverage support?
diff --git a/.gitlab-ci/test-msys2.sh b/.gitlab-ci/test-msys2.sh
index d891ee008f..78b27d33d8 100755
--- a/.gitlab-ci/test-msys2.sh
+++ b/.gitlab-ci/test-msys2.sh
@@ -43,20 +43,6 @@ meson --werror --buildtype debug _build
cd _build
ninja
-lcov \
- --quiet \
- --config-file "${DIR}"/.lcovrc \
- --directory "${DIR}/_build" \
- --capture \
- --initial \
- --output-file "${DIR}/_coverage/${CI_JOB_NAME}-baseline.lcov"
-
# FIXME: fix the test suite
-meson test --timeout-multiplier "${MESON_TEST_TIMEOUT_MULTIPLIER}" --no-suite flaky || true
-
-lcov \
- --quiet \
- --config-file "${DIR}"/.lcovrc \
- --directory "${DIR}/_build" \
- --capture \
- --output-file "${DIR}/_coverage/${CI_JOB_NAME}.lcov"
+meson test --benchmark -v --timeout-multiplier "${MESON_TEST_TIMEOUT_MULTIPLIER}" --no-suite flaky || true
+
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]