-
Notifications
You must be signed in to change notification settings - Fork 0
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
apply lockout for non fictional switch #500
Conversation
Signed-off-by: maissa SOUISSI <[email protected]>
Signed-off-by: maissa SOUISSI <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure we want to do the change in this service. Don't we want to change it in network-store in the default method?
What's the purpose of the change? To change the disconnect behavior or only for a very specific case?
It seems very strange (wrong?) to have the two types of disconnect mixed together inside the same modification
Also, I thought we just needed to ignore fictional switch, the default was IS_CLOSED_BREAKER so I would have chosen IS_NONFICTIONAL_CLOSED_BREAKER, why IS_NONFICTIONAL_BREAKER?
=> discussed with PO, we only want to change the lockout behavior
I also don't really understand the changes in the tests.
We can also fix the sonar issue
cc @SlimaneAmar
} | ||
|
||
private boolean disconnectOneTerminal(Terminal terminal) { | ||
return !terminal.isConnected() || terminal.disconnect(); | ||
} | ||
|
||
private boolean disconnectNonFictionalOneTerminal(Terminal terminal) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove NonFictional
in the name and pass the predicate in argument
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
.add(); | ||
assertNotNull(line); | ||
|
||
line.getTerminal("v1f").disconnect(SwitchPredicates.IS_NONFICTIONAL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't understand !
Need to create a fictional switch and test disconnect
And another tests each with a type of switch ?
.../gridsuite/modification/server/modifications/OperatingStatusModificationLockoutLineTest.java
Outdated
Show resolved
Hide resolved
Signed-off-by: maissa SOUISSI <[email protected]>
Signed-off-by: maissa SOUISSI <[email protected]>
.../gridsuite/modification/server/modifications/OperatingStatusModificationLockoutLineTest.java
Outdated
Show resolved
Hide resolved
src/test/java/org/gridsuite/modification/server/utils/NetworkCreation.java
Show resolved
Hide resolved
src/test/java/org/gridsuite/modification/server/utils/NetworkCreation.java
Outdated
Show resolved
Hide resolved
Signed-off-by: maissa SOUISSI <[email protected]>
Signed-off-by: maissa SOUISSI <[email protected]>
@Test | ||
public void testLockoutLinesWithLoadBreakerSwitches() throws Exception { | ||
//Lockout line with switches of kind LOAD_BREAK_SWITCH | ||
getNetwork().getSwitch("br11").setProperty("Kind", SwitchKind.LOAD_BREAK_SWITCH.toString()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A property does not modify the type !
Signed-off-by: maissa SOUISSI <[email protected]>
…/gridsuite/network-modification-server into lockout-for-non-fictional-switch
@@ -73,20 +99,46 @@ protected void assertAfterNetworkModificationCreation() { | |||
TestUtils.assertOperatingStatus(getNetwork(), TARGET_LINE_ID, TARGET_BRANCH_STATUS); | |||
} | |||
|
|||
private void assertAfterNetworkModificationLockout(String lineID) throws Exception { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rename by testLockoutLine
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
.../gridsuite/modification/server/modifications/OperatingStatusModificationLockoutLineTest.java
Outdated
Show resolved
Hide resolved
.../gridsuite/modification/server/modifications/OperatingStatusModificationLockoutLineTest.java
Show resolved
Hide resolved
Remove the Sonar issue |
Signed-off-by: maissa SOUISSI <[email protected]>
Signed-off-by: maissa SOUISSI <[email protected]>
Signed-off-by: maissa SOUISSI <[email protected]>
…/gridsuite/network-modification-server into lockout-for-non-fictional-switch
Signed-off-by: maissa SOUISSI <[email protected]>
Quality Gate passedIssues Measures |
No description provided.