Skip to content
This repository was archived by the owner on Jan 27, 2026. It is now read-only.

Discovery state change tests#171

Merged
JannikSt merged 4 commits into
developfrom
improvement/discovery-state-change-tests
Mar 26, 2025
Merged

Discovery state change tests#171
JannikSt merged 4 commits into
developfrom
improvement/discovery-state-change-tests

Conversation

@JannikSt
Copy link
Copy Markdown
Member

No description provided.

@JannikSt JannikSt requested a review from Copilot March 26, 2025 19:13
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refactors the discovery node synchronization logic and adds tests to validate state changes. Key changes include:

  • Refactoring the get_nodes method to loop over discovery nodes via a new sync_single_node_with_discovery function.
  • Converting the node identifier to an Address type and updating status transition logic.
  • Adding tests for node synchronization behavior.

Comment thread orchestrator/src/discovery/monitor.rs Outdated
@JannikSt JannikSt requested a review from Copilot March 26, 2025 19:20
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces changes to improve how discovery state changes are synchronized and adds tests to validate these behaviors.

  • Replace unwrap calls with proper error propagation via the ? operator.
  • Introduce a new function, sync_single_node_with_discovery, to update node states based on discovery data.
  • Add a test for sync_single_node_with_discovery to verify state transitions.

@JannikSt JannikSt merged commit 840c7e8 into develop Mar 26, 2025
JannikSt added a commit that referenced this pull request Apr 12, 2025
* rewrite orchestrator discovery sync to make it testable

* fix & test discvoery state changes, add logs when state changes
@JannikSt JannikSt deleted the improvement/discovery-state-change-tests branch June 25, 2025 13:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants