Skip to content

fix(config): validate empty and overlapping port ranges#38

Open
FFFergie wants to merge 1 commit into
gupsammy:masterfrom
FFFergie:fix/issue-33-config-validation
Open

fix(config): validate empty and overlapping port ranges#38
FFFergie wants to merge 1 commit into
gupsammy:masterfrom
FFFergie:fix/issue-33-config-validation

Conversation

@FFFergie

Copy link
Copy Markdown

Summary

  • Add config validation to reject empty monitoring.port_ranges.
  • Add overlap detection for port ranges after sorting, with clear error messages.
  • Add unit tests covering empty ranges, overlapping ranges (sorted/unsorted), and valid non-overlapping ranges.

Validation

  • cargo test currently fails on upstream master due to pre-existing let-chain compatibility errors in unrelated files (src/app.rs, src/process/ports.rs, src/integrations/brew.rs, src/integrations/docker.rs).
  • The new config tests are included in this PR but full test execution is blocked by that existing baseline issue.

Closes #33

Addresses gupsammy#33 by rejecting empty and overlapping monitoring ranges with tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Config validation gaps - overlapping ranges, empty ranges not caught

1 participant