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

kubernetes-sigs / karpenter / 20975167016
81%
main: 81%

Build:
Build:
LAST BUILD BRANCH: refactor-nodeclaimtemplate-offerings
DEFAULT BRANCH: main
Ran 13 Jan 2026 10:52PM UTC
Jobs 1
Files 153
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

13 Jan 2026 10:38PM UTC coverage: 80.703%. First build
20975167016

Pull #2781

github

ellistarn
fix: deflake nomination test by using injected clock

## Description

The nomination test was flaky because `Nominate()` and `Nominated()`
used `time.Now()` directly while the test used `time.Sleep()` for
real-time delays. In CI environments with timing jitter, the 21-second
sleep could sometimes not exceed the 20-second nomination window.

This fix injects the clock into StateNode so nomination timing uses
the test's fake clock instead of real time.

## Testing

```
go test ./pkg/controllers/state/... -v
go test ./pkg/controllers/... -count=1
```

All tests pass. The nomination test now runs instantly instead of
sleeping for 21 seconds.
Pull Request #2781: fix: deflake nomination test by using injected clock

9 of 9 new or added lines in 3 files covered. (100.0%)

12015 of 14888 relevant lines covered (80.7%)

120093.25 hits per line

Jobs
ID Job ID Ran Files Coverage
1 20975167016.1 13 Jan 2026 10:52PM UTC 153
80.7
GitHub Action Run
Source Files on build 20975167016
  • Tree
  • List 153
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Pull Request #2781
  • Delete
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