From eb8c91de7d3ebfa71d8e173ee0b3d4bfa87aaef8 Mon Sep 17 00:00:00 2001 From: Rasmus Karlsson Date: Fri, 21 Feb 2025 22:31:15 +0100 Subject: [PATCH 1/4] chore(ci): try to include twitch-eventsub-ws in coverage switch to `-coverage` flag for gcc/clang - not sure of other platform support --- src/CMakeLists.txt | 27 +++++++++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 05a83ebd8ca..33c286a0cfe 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -781,14 +781,37 @@ endif() if (CHATTERINO_GENERATE_COVERAGE) include(CodeCoverage) - append_coverage_compiler_flags_to_target(${LIBRARY_PROJECT}) + if(CMAKE_CXX_COMPILER_ID MATCHES "(GNU|Clang)") + target_compile_options(${LIBRARY_PROJECT} PRIVATE -coverage) + target_link_options(${LIBRARY_PROJECT} PRIVATE -coverage) + else() + append_coverage_compiler_flags_to_target(${LIBRARY_PROJECT}) + endif() message(STATUS "project source dir: ${PROJECT_SOURCE_DIR}/src") setup_target_for_coverage_gcovr_html( NAME coverage EXECUTABLE ctest EXCLUDE "/usr/include/*" EXCLUDE "build-*/*" - EXCLUDE "lib/*" + # EXCLUDE "lib/*" + EXCLUDE "lib/certify/*" + EXCLUDE "lib/expected-lite/*" + EXCLUDE "lib/googletest/*" + EXCLUDE "lib/libcommuni/*" + EXCLUDE "lib/lrucache/*" + EXCLUDE "lib/lua/*" + EXCLUDE "lib/magic_enum/*" + EXCLUDE "lib/miniaudio/*" + EXCLUDE "lib/qtkeychain/*" + EXCLUDE "lib/rapidjson/*" + EXCLUDE "lib/semver/*" + EXCLUDE "lib/serialize/*" + EXCLUDE "lib/settings/*" + EXCLUDE "lib/signals/*" + EXCLUDE "lib/sol2/*" + EXCLUDE "lib/websocketpp/*" + EXCLUDE "lib/WinToast/*" + EXCLUDE "*/ui_*.h" EXCLUDE "*/moc_*.cpp" ) From 8e349665f7b81426389c43adca610cce19acc6cf Mon Sep 17 00:00:00 2001 From: Rasmus Karlsson Date: Fri, 21 Feb 2025 22:31:49 +0100 Subject: [PATCH 2/4] chore(ci): exclude all build dirs from coverage --- src/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 33c286a0cfe..4c09fa60353 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -792,7 +792,7 @@ if (CHATTERINO_GENERATE_COVERAGE) NAME coverage EXECUTABLE ctest EXCLUDE "/usr/include/*" - EXCLUDE "build-*/*" + EXCLUDE "build*/*" # EXCLUDE "lib/*" EXCLUDE "lib/certify/*" EXCLUDE "lib/expected-lite/*" From 311ab584ff4e1f6b1a814f6d0993907351ebbbf1 Mon Sep 17 00:00:00 2001 From: Rasmus Karlsson Date: Sat, 22 Feb 2025 08:56:42 +0100 Subject: [PATCH 3/4] try some codecov changes --- .codecov.yml | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/.codecov.yml b/.codecov.yml index db76994483b..436172203c3 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -2,6 +2,25 @@ comment: false ignore: - "/usr/local*/**/*" - "/usr/include/**/*" - - "lib/" + - "lib/certify/*" + - "lib/expected-lite/*" + - "lib/googletest/*" + - "lib/libcommuni/*" + - "lib/lrucache/*" + - "lib/lua/*" + - "lib/magic_enum/*" + - "lib/miniaudio/*" + - "lib/qtkeychain/*" + - "lib/rapidjson/*" + - "lib/semver/*" + - "lib/serialize/*" + - "lib/settings/*" + - "lib/signals/*" + - "lib/sol2/*" + - "lib/websocketpp/*" + - "lib/WinToast/*" + - "build*/" - "**/ui_*.h" - "**/moc_*.cpp" +fixes: + - "__w/chatterino2/chatterino2/::" From 8fd53910171b46f2832b083bf4195715d8495880 Mon Sep 17 00:00:00 2001 From: Rasmus Karlsson Date: Sat, 22 Feb 2025 09:20:56 +0100 Subject: [PATCH 4/4] super-globbing --- .codecov.yml | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/.codecov.yml b/.codecov.yml index 436172203c3..705e496a423 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -1,25 +1,25 @@ comment: false ignore: - - "/usr/local*/**/*" - - "/usr/include/**/*" - - "lib/certify/*" - - "lib/expected-lite/*" - - "lib/googletest/*" - - "lib/libcommuni/*" - - "lib/lrucache/*" - - "lib/lua/*" - - "lib/magic_enum/*" - - "lib/miniaudio/*" - - "lib/qtkeychain/*" - - "lib/rapidjson/*" - - "lib/semver/*" - - "lib/serialize/*" - - "lib/settings/*" - - "lib/signals/*" - - "lib/sol2/*" - - "lib/websocketpp/*" - - "lib/WinToast/*" - - "build*/" + - "**/usr/local*/**/*" + - "**/usr/include/**/*" + - "**/lib/certify/*" + - "**/lib/expected-lite/*" + - "**/lib/googletest/*" + - "**/lib/libcommuni/*" + - "**/lib/lrucache/*" + - "**/lib/lua/*" + - "**/lib/magic_enum/*" + - "**/lib/miniaudio/*" + - "**/lib/qtkeychain/*" + - "**/lib/rapidjson/*" + - "**/lib/semver/*" + - "**/lib/serialize/*" + - "**/lib/settings/*" + - "**/lib/signals/*" + - "**/lib/sol2/*" + - "**/lib/websocketpp/*" + - "**/lib/WinToast/*" + - "**/build*/" - "**/ui_*.h" - "**/moc_*.cpp" fixes: