• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stacklok / toolhive / 17941639158
59%

Build:
DEFAULT BRANCH: main
Ran 23 Sep 2025 09:33AM UTC
Jobs 1
Files 271
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

23 Sep 2025 09:29AM UTC coverage: 44.695% (-0.001%) from 44.696%
17941639158

push

github

web-flow
Fix flaky TestGetRegistryAPIImage test by using dependency injection (#2002)

The test was flaky because it manipulated global environment variables
while running in parallel, causing race conditions between test cases.

This change refactors the getRegistryAPIImage function to accept an
environment getter function parameter, allowing tests to use isolated
mock functions instead of manipulating global state.

Changes:
- Add getRegistryAPIImageWithEnvGetter function for dependency injection
- Update test to use mock environment getter instead of os.Setenv/Unsetenv
- Remove unused os import from test file
- Maintain backward compatibility with existing getRegistryAPIImage function

The test now runs reliably in parallel without race conditions.

4 of 4 new or added lines in 1 file covered. (100.0%)

4 existing lines in 1 file now uncovered.

15700 of 35127 relevant lines covered (44.69%)

15.65 hits per line

Uncovered Existing Lines

Lines Coverage ∆ File
4
44.56
-0.52% pkg/workloads/manager.go
Jobs
ID Job ID Ran Files Coverage
1 17941639158.1 23 Sep 2025 09:33AM UTC 271
44.69
GitHub Action Run
Source Files on build 17941639158
  • Tree
  • List 271
  • Changed 3
  • Source Changed 1
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #17941639158
  • 5df8be53 on github
  • Prev Build on main (#17940161494)
  • Next Build on main (#17972951344)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc