test(refresh): cover the manager gate and the status reconciliation (3/6) - #265
Draft
marceloneppel wants to merge 1 commit into
Draft
test(refresh): cover the manager gate and the status reconciliation (3/6)#265marceloneppel wants to merge 1 commit into
marceloneppel wants to merge 1 commit into
Conversation
…3/5) Covers the refresh-aware status gate (higher-priority suppression, lower- priority substitution for active statuses with the .last_refresh_unit_status.json caching, non-active statuses written directly, explicit refresh argument) and the collect-unit-status reconciliation (higher-priority status set and cached, stale cached status cleared through the set_default_status bridge or restored from the lower-priority status, unrelated statuses left alone), plus the manager construction paths: the K8s untrusted-app case disabling app status and PeerRelationNotReady leaving the refresh object unset. Drops the file-local refresh_versions.toml fixture, now provided for every test by the conftest shunt.
This was referenced Sep 4, 2026
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.
Issue
Part of the refresh module migration from the PostgreSQL VM and K8s charms' 16/edge branches into this library. Stacks on #264.
Solution
Covers the refresh-aware status gate (higher-priority suppression, lower-priority substitution for active statuses with the
.last_refresh_unit_status.jsoncaching, non-active statuses written directly, explicit refresh argument) and the collect-unit-status reconciliation (higher-priority status set and cached, stale cached status cleared through theset_default_statusbridge or restored from the lower-priority status, unrelated statuses left alone), plus the manager construction paths: the K8s untrusted-app case disabling app status andPeerRelationNotReadyleaving the refresh object unset.Drops the file-local
refresh_versions.tomlfixture, now provided for every test by the conftest shunt introduced in #264. The fixture anchors its paths on the setup-time working directory so per-testchdirs cannot corrupt the teardown.Checklist