18
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-28 11:26:19 +01:00
Commit Graph

6 Commits

Author SHA1 Message Date
jerrrrycho
92bd7066d4 ci: cache the apt packages of the Linux jobs, install only the X11 headers GLFW needs (#497)
* ci: cache the apt packages of the Linux jobs, install only the X11 headers GLFW needs

The "Install Linux dependencies" step timed out after 15 minutes in many runs: the
runners' Ubuntu mirror delivered about 150 kB/s, with 30 s stalls on single files,
and the step downloaded 136 packages (32.4 MB) every time.

- a local action, .github/actions/apt-install, keeps the downloaded .deb files in the
  Actions cache, keyed by the runner image and the package list. With the same image
  and list it installs the cached files without apt-get update and without the
  mirror; otherwise it runs apt-get update and downloads only what the cache lacks
- --no-install-recommends, and Acquire::Languages "none" for apt-get update
- xorg-dev (about 45 packages nothing used) is replaced by the X11 headers GLFW 3.4
  checks for: libx11-dev, libxcursor-dev, libxext-dev, libxi-dev, libxinerama-dev,
  libxrandr-dev; pkg-config is listed, as it is only a recommendation of libsndfile1-dev
- Build, Build binaries and Coverage use it; Coverage gets the 15-minute step timeout
  and the apt retries too
- Dependabot also updates the actions pinned in .github/actions

* ci: a repaired apt cache is saved under a key of its own run, and the newest one is restored
2026-11-25 05:41:39 +01:00
jerrrrycho
e64546385b ci: pin actions/checkout in the Coverage workflow to v6.1.0, as in build_bin.yml 2026-11-11 14:26:41 +01:00
jerrrrycho
666153473b ci: install gcovr from wheels only
SonarQube Cloud failed the quality gate of the pull request on this line (githubactions:S8541, a new vulnerability): without --only-binary :all: pip may run the setup script of a source package. gcovr 8.3 and its five dependencies all have wheels for Python 3.14 on Linux, as the first two runs show.
2026-11-11 11:33:12 +01:00
jerrrrycho
c008d0cdca ci: fail the coverage report step when gcovr fails
The step pipes gcovr into tee, and the default shell of a run step has no pipefail: an error of gcovr after it printed the totals would have left the step green with an incomplete report.
2026-11-11 11:03:09 +01:00
jerrrrycho
4533fafd93 ci: leave yaml-cpp out of the coverage report
The first run of the Coverage workflow listed 66 files of betterRenderer/thirdparty/yaml-cpp, all at 0%: the library is linked by every target of the game, so it's built with the coverage flags as well. They made up 4388 of the 16592 lines and took the total from 84.4% to 62.1%. betterRenderer/ is excluded as it is in sonar-project.properties.
2026-11-11 11:02:59 +01:00
jerrrrycho
c01007b9dd ci: measure the coverage of the core library by the unit tests
A new Coverage workflow builds the unit tests with GCC and gcov (unoptimised, the tests and the core library only), runs them and reports with gcovr: the totals and the per-file table in the summary of the run, the HTML report and the SonarQube generic coverage file in the unit-test-coverage artifact.

The report isn't sent to SonarQube Cloud. The project's quality gate (Sonar way) fails a pull request whose new code is covered in less than 80%; that condition isn't evaluated today because sonar-project.properties excludes every file from coverage, and sending the report would turn it on.
2026-11-11 10:49:03 +01:00