-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix busbar section minimal tripping #1142
base: main
Are you sure you want to change the base?
Conversation
I still need to add a unit test! |
Quality Gate passedIssues Measures |
To me there's no easy way to include a unit test, could we merge it like this? The unit test would be really complex to write for just having swapped two arguments, I think this is not worth the effort. The original mistake of adding the traversed terminal to the list of neighbouring terminals (to later visit) instead of the set of traversed terminals (to disconnect) has no impact at the end. Indeed, the neighbouring terminals are later visited and added to the set of traversed terminals. |
I realized that there is no simple test in ContingencyTrippingTest that goes through the line that uses traversedTerminals (nbv.getOptionalTerminal(nodeAfter).ifPresent(traversedTerminals::add);) |
Test added. As you said, it worked also on main without your fix. But at least we have a unit test for this tripping that as otherwised only exercised by SA tests. |
Signed-off-by: Florian Dupuy <[email protected]>
Signed-off-by: Didier Vidal <[email protected]>
c99144b
to
90fcaf3
Compare
Quality Gate passedIssues Measures |
Please check if the PR fulfills these requirements
Does this PR already have an issue describing the problem?
No
What kind of change does this PR introduce?
Bug fix
What is the current behavior?
The tripping corresponding to a bbs contingency with no propagation adds the traversed terminals in the neigbours list.
What is the new behavior (if this is a feature change)?
The tripping corresponding to a bbs contingency with no propagation adds the visited terminals in the traversed terminals set.
Does this PR introduce a breaking change or deprecate an API?