client: add seamed unit tests for onboarding loop#5958
Open
eriknordmark wants to merge 1 commit into
Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #5958 +/- ##
==========================================
+ Coverage 22.69% 23.33% +0.63%
==========================================
Files 507 517 +10
Lines 93195 94911 +1716
==========================================
+ Hits 21151 22147 +996
- Misses 70317 70842 +525
- Partials 1727 1922 +195 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This was referenced May 15, 2026
eriknordmark
marked this pull request as ready for review
July 1, 2026 23:53
eriknordmark
requested review from
andrewd-zededa,
christoph-zededa,
europaul,
rene and
zedi-pramodh
July 2, 2026 00:06
eriknordmark
force-pushed
the
client-phase2-tests
branch
from
July 2, 2026 00:44
42f74c7 to
148daa7
Compare
eriknordmark
force-pushed
the
client-phase2-tests
branch
from
July 10, 2026 03:03
148daa7 to
415138b
Compare
rene
reviewed
Jul 15, 2026
| wantLed: []types.LedBlinkCount{types.LedBlinkOnboarded}, | ||
| }, | ||
| { | ||
| name: "200 unparseable content-type", |
Contributor
Author
There was a problem hiding this comment.
Fixed in 169d88c91 — unparseable → unparsable.
eriknordmark
force-pushed
the
client-phase2-tests
branch
3 times, most recently
from
July 16, 2026 13:29
7e8cdfb to
866dee0
Compare
eriknordmark
force-pushed
the
client-phase2-tests
branch
2 times, most recently
from
July 20, 2026 22:07
2deedfa to
5518c42
Compare
Cover the network-facing and side-effect-bearing parts of the onboarding loop using the seams introduced earlier: HTTP request classification and LED transitions, the register/UUID-fetch outcomes, controller-cert prefetch with checkpoint comparison, the post-loop hostname/UUID/hardwaremodel publishing, and the DNS-status handler's state-transition + proxy-cert propagation paths. Package statement coverage rises from ~10% to ~54%. Each function the new tests target reaches 80-100%; the remaining dark code is the top-level event loop and adapter wiring, reached by Eden e2e tests in a follow-up. Signed-off-by: eriknordmark <erik@zededa.com> Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
eriknordmark
force-pushed
the
client-phase2-tests
branch
from
July 21, 2026 06:42
5518c42 to
34155cf
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Cover the network-facing and side-effect-bearing parts of the
onboarding loop using the seams introduced earlier: HTTP request
classification and LED transitions, the register/UUID-fetch outcomes,
controller-cert prefetch with checkpoint comparison, the post-loop
hostname/UUID/hardwaremodel publishing, and the DNS-status handler's
state-transition + proxy-cert propagation paths.
Package statement coverage rises from 0 % to 53.66 % (242/451)
across the Phase-1 (#5957) and Phase-2 sets combined. Each function the
new tests target reaches 80-100%; the remaining dark code is the
top-level event loop and adapter wiring, reached by Eden e2e tests in
lf-edge/eden#1178.
With the Eden e2e suite included,
pkg/pillar/cmd/clientcombinedblock coverage reaches 85.59 % (386/451, dedup'd across unit and
e2e profiles).
Depends on #5957.
How to test and validate this PR
go test -count=1 -cover ./pkg/pillar/cmd/client/...from the pillar module.Changelog notes
No user-facing changes.
PR Backports
Checklist