diff --git a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/SclService.java b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/SclService.java index 006075c87..a2aec92e2 100644 --- a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/SclService.java +++ b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/SclService.java @@ -6,7 +6,6 @@ import lombok.NonNull; import lombok.extern.slf4j.Slf4j; -import org.apache.commons.lang3.tuple.Pair; import org.lfenergy.compas.scl2007b4.model.*; import org.lfenergy.compas.sct.commons.api.SclEditor; import org.lfenergy.compas.sct.commons.dto.*; @@ -24,7 +23,6 @@ import org.lfenergy.compas.sct.commons.scl.ldevice.LDeviceAdapter; import org.lfenergy.compas.sct.commons.scl.ln.AbstractLNAdapter; import org.lfenergy.compas.sct.commons.scl.ln.LN0Adapter; -import org.lfenergy.compas.sct.commons.scl.sstation.SubstationAdapter; import org.lfenergy.compas.sct.commons.util.PrivateUtils; import org.lfenergy.compas.sct.commons.util.Utils; @@ -187,19 +185,6 @@ public void importSTDElementsInSCD(SCL scd, List stds) throws ScdException }); } - @Override - public List updateLDeviceStatus(SCL scd) { - SclRootAdapter sclRootAdapter = new SclRootAdapter(scd); - SubstationAdapter substationAdapter = sclRootAdapter.getSubstationAdapter(); - final List> iedNameLdInstList = substationAdapter.getIedAndLDeviceNamesForLN0FromLNode(); - return sclRootAdapter.streamIEDAdapters() - .flatMap(IEDAdapter::streamLDeviceAdapters) - .map(LDeviceAdapter::getLN0Adapter) - .map(ln0Adapter -> ln0Adapter.updateLDeviceStatus(iedNameLdInstList)) - .flatMap(Optional::stream) - .toList(); - } - @Override public List updateDoInRef(SCL scd) { SclRootAdapter sclRootAdapter = new SclRootAdapter(scd); diff --git a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/api/SclEditor.java b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/api/SclEditor.java index 1040f0ea0..985b436f2 100644 --- a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/api/SclEditor.java +++ b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/api/SclEditor.java @@ -6,7 +6,6 @@ import lombok.NonNull; import org.lfenergy.compas.scl2007b4.model.SCL; -import org.lfenergy.compas.scl2007b4.model.TLNode; import org.lfenergy.compas.sct.commons.dto.*; import org.lfenergy.compas.sct.commons.exception.ScdException; @@ -137,14 +136,6 @@ public interface SclEditor { */ void importSTDElementsInSCD(SCL scd, List stds) throws ScdException; - /** - * Activate used LDevice and Deactivate unused LDevice in {@link TLNode TLNode } - * - * @param scd SCL file for which LDevice should be activated or deactivated - * @return list of encountered errors - */ - List updateLDeviceStatus(SCL scd); - /** * Update DAIs of DO InRef in all LN0 of the SCD using matching ExtRef information. * diff --git a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/ldevice/LDeviceActivation.java b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/ldevice/LDeviceActivation.java deleted file mode 100644 index 284c3c863..000000000 --- a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/ldevice/LDeviceActivation.java +++ /dev/null @@ -1,122 +0,0 @@ -// SPDX-FileCopyrightText: 2022 RTE FRANCE -// -// SPDX-License-Identifier: Apache-2.0 - -package org.lfenergy.compas.sct.commons.scl.ldevice; - -import lombok.Getter; -import lombok.Setter; -import org.apache.commons.lang3.tuple.Pair; -import org.lfenergy.compas.scl2007b4.model.TCompasLDeviceStatus; -import org.lfenergy.compas.sct.commons.util.ActiveStatus; - -import java.util.List; -import java.util.Set; - -/** - * Common class for all states that define if LDevice should be activated or not - * regardless of the CompasLDeviceStatus Private, Enum Values of DO 'Beh' and if it's referenced in Substation...LNode or not - */ -@Getter -@Setter -public class LDeviceActivation { - - private final List> iedNameLdInstList; - private boolean isUpdatable; - private String newVal; - private String errorMessage; - - public LDeviceActivation(List> iedNameLdInstList) { - this.iedNameLdInstList = iedNameLdInstList; - } - - /** - * checks whether LDevice status is authorized to be activated or Not - * @param iedName Ied name value which LDevice appear - * @param ldInst LDevice inst value - * @param compasLDeviceStatus Private value - * @param enumValues enum values - */ - public void checkLDeviceActivationStatus(String iedName, String ldInst, TCompasLDeviceStatus compasLDeviceStatus, Set enumValues) { - if (!enumValues.contains(ActiveStatus.ON.getValue()) && !enumValues.contains(ActiveStatus.OFF.getValue())) { - errorMessage = "The LDevice cannot be activated or desactivated because its BehaviourKind Enum contains NOT 'on' AND NOT 'off'."; - } - if (!enumValues.contains(ActiveStatus.ON.getValue()) && enumValues.contains(ActiveStatus.OFF.getValue())) { - if (isDeclaredInSubstation(iedName, ldInst)) { - errorMessage = "The LDevice cannot be set to 'on' but has been selected into SSD."; - } else { - isUpdatable = true; - newVal = ActiveStatus.OFF.getValue(); - } - } - if(compasLDeviceStatus.equals(TCompasLDeviceStatus.ACTIVE) || - compasLDeviceStatus.equals(TCompasLDeviceStatus.UNTESTED)){ - checkAuthorisationToActivateLDevice(iedName, ldInst, enumValues); - } - if(compasLDeviceStatus.equals(TCompasLDeviceStatus.INACTIVE)){ - checkAuthorisationToDeactivateLDevice(iedName, ldInst, enumValues); - } - } - - /** - * checks whether LDevice status is authorized to be activated when CompasLDeviceStatus Private is ACTIVE or UNTESTED - * @param iedName Ied name value which contains LDevice - * @param ldInst LDevice inst value - * @param enumValues enum values - */ - private void checkAuthorisationToActivateLDevice(String iedName, String ldInst, Set enumValues) { - if (!enumValues.contains(ActiveStatus.OFF.getValue()) && enumValues.contains(ActiveStatus.ON.getValue())) { - if (isDeclaredInSubstation(iedName, ldInst)) { - isUpdatable = true; - newVal = ActiveStatus.ON.getValue(); - } else { - errorMessage = "The LDevice cannot be set to 'off' but has not been selected into SSD."; - } - } - if (enumValues.contains(ActiveStatus.ON.getValue()) && enumValues.contains(ActiveStatus.OFF.getValue())) { - isUpdatable = true; - if (isDeclaredInSubstation(iedName, ldInst)) { - newVal = ActiveStatus.ON.getValue(); - } else { - newVal = ActiveStatus.OFF.getValue(); - } - } - - } - - /** - * checks whether LDevice Status is authorized to be deactivated when CompasLDeviceStatus Private is INACTIVE - * @param iedName Ied name value which contains LDevice - * @param ldInst LDevice inst value - * @param enumValues enum values - */ - private void checkAuthorisationToDeactivateLDevice(String iedName, String ldInst, Set enumValues) { - if (!enumValues.contains(ActiveStatus.OFF.getValue()) && enumValues.contains(ActiveStatus.ON.getValue())) { - if (isDeclaredInSubstation(iedName, ldInst)) { - errorMessage = "The LDevice is not qualified into STD but has been selected into SSD."; - } else { - errorMessage = "The LDevice cannot be set to 'off' but has not been selected into SSD."; - } - } - if (enumValues.contains(ActiveStatus.ON.getValue()) && enumValues.contains(ActiveStatus.OFF.getValue())) { - if (isDeclaredInSubstation(iedName, ldInst)) { - errorMessage = "The LDevice is not qualified into STD but has been selected into SSD."; - } else { - isUpdatable = true; - newVal = ActiveStatus.OFF.getValue(); - } - } - } - - /** - * checks whether a pair of IED name and LDevice inst are referenced in Substation...LNode list - * @param iedName Ied name value - * @param ldInst LDevice inst value - * @return Returns whether a pair of IED name and LDevice inst are referenced in Substation...LNode list - */ - private boolean isDeclaredInSubstation(String iedName, String ldInst){ - return iedNameLdInstList.contains(Pair.of(iedName, ldInst)); - } - - -} diff --git a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/ln/LN0Adapter.java b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/ln/LN0Adapter.java index 09836f9cc..705a0fff1 100644 --- a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/ln/LN0Adapter.java +++ b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/ln/LN0Adapter.java @@ -5,18 +5,12 @@ package org.lfenergy.compas.sct.commons.scl.ln; -import org.apache.commons.lang3.tuple.Pair; import org.lfenergy.compas.scl2007b4.model.*; import org.lfenergy.compas.sct.commons.dto.*; import org.lfenergy.compas.sct.commons.scl.ObjectReference; import org.lfenergy.compas.sct.commons.scl.ied.InputsAdapter; -import org.lfenergy.compas.sct.commons.scl.ldevice.LDeviceActivation; import org.lfenergy.compas.sct.commons.scl.ldevice.LDeviceAdapter; -import org.lfenergy.compas.sct.commons.util.PrivateUtils; - import java.util.List; -import java.util.Optional; -import java.util.Set; import java.util.regex.Pattern; import java.util.stream.Collectors; @@ -68,8 +62,6 @@ */ public class LN0Adapter extends AbstractLNAdapter { - public static final DoTypeName BEHAVIOUR_DO_TYPE_NAME = new DoTypeName(BEHAVIOUR_DO_NAME); - public static final DaTypeName BEHAVIOUR_DA_TYPE_NAME = getDaTypeNameForBeh(); private static final Pattern LDEFP_DIGITAL_CHANNEL_PATTERN = Pattern.compile("DYN_LDEPF_DIGITAL CHANNEL \\d+_\\d+_BOOLEAN"); /** @@ -169,58 +161,6 @@ public void removeAllControlBlocksAndDatasets() { currentElem.unsetSampledValueControl(); } - /** - * Verify and update LDevice status in parent Node - * - * @param iedNameLDeviceInstList pair of Ied name and LDevice inst attributes - * @return Set of Errors - */ - public Optional updateLDeviceStatus(List> iedNameLDeviceInstList) { - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLDeviceInstList); - final String iedName = getParentAdapter().getParentAdapter().getName(); - final String ldInst = getParentAdapter().getInst(); - DataAttributeRef daiBehFilter = new DataAttributeRef(this, BEHAVIOUR_DO_TYPE_NAME, BEHAVIOUR_DA_TYPE_NAME); - List daiBehList = getDAI(daiBehFilter, false); - if (daiBehList.isEmpty()) { - return Optional.of(buildFatalReportItem("The LDevice doesn't have a DO @name='Beh' OR its associated DA@fc='ST' AND DA@name='stVal'")); - } - Set enumValues = getEnumValues(daiBehList.getFirst().getDaName().getType()); - Optional optionalTCompasLDevice = PrivateUtils.extractCompasPrivate(getParentAdapter().getCurrentElem(), TCompasLDevice.class); - if (optionalTCompasLDevice.isEmpty()) { - return Optional.of(buildFatalReportItem("The LDevice doesn't have a Private compas:LDevice.")); - } - if (!optionalTCompasLDevice.get().isSetLDeviceStatus()) { - return Optional.of(buildFatalReportItem("The Private compas:LDevice doesn't have the attribute 'LDeviceStatus'")); - } - TCompasLDeviceStatus compasLDeviceStatus = optionalTCompasLDevice.get().getLDeviceStatus(); - Optional optionalModStVal = getDaiModStVal(); - if (optionalModStVal.isEmpty()) { - return Optional.of(buildFatalReportItem("The LDevice doesn't have a DO @name='Mod'")); - } - DataAttributeRef newDaModToSetInLN0 = optionalModStVal.get(); - String initialValue = newDaModToSetInLN0.findFirstValue().orElse(""); - lDeviceActivation.checkLDeviceActivationStatus(iedName, ldInst, compasLDeviceStatus, enumValues); - if (lDeviceActivation.isUpdatable()) { - if (!initialValue.equals(lDeviceActivation.getNewVal())) { - newDaModToSetInLN0.setVal(lDeviceActivation.getNewVal()); - updateDAI(newDaModToSetInLN0); - } - } else { - if (lDeviceActivation.getErrorMessage() != null) { - return Optional.of(buildFatalReportItem(lDeviceActivation.getErrorMessage())); - } - } - return Optional.empty(); - } - - private static DaTypeName getDaTypeNameForBeh() { - DaTypeName daTypeNameBeh = new DaTypeName(); - daTypeNameBeh.setName(STVAL_DA_NAME); - daTypeNameBeh.setBType(TPredefinedBasicTypeEnum.ENUM); - daTypeNameBeh.setFc(TFCEnum.ST); - return daTypeNameBeh; - } - /** * Update DAIs of DO InRef in all LN0 of the SCD using matching ExtRef information. * diff --git a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapter.java b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapter.java index 02d9ce17c..1b68bc99f 100644 --- a/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapter.java +++ b/sct-commons/src/main/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapter.java @@ -4,17 +4,13 @@ package org.lfenergy.compas.sct.commons.scl.sstation; -import org.apache.commons.lang3.tuple.Pair; -import org.lfenergy.compas.scl2007b4.model.TLLN0Enum; import org.lfenergy.compas.scl2007b4.model.TSubstation; import org.lfenergy.compas.sct.commons.exception.ScdException; import org.lfenergy.compas.sct.commons.scl.SclElementAdapter; import org.lfenergy.compas.sct.commons.scl.SclRootAdapter; import org.lfenergy.compas.sct.commons.util.Utils; -import java.util.List; import java.util.Optional; -import java.util.stream.Collectors; import java.util.stream.Stream; /** @@ -119,18 +115,4 @@ public Stream streamVoltageLevelAdapters() { return currentElem.getVoltageLevel().stream().map(tVoltageLevel -> new VoltageLevelAdapter(this, tVoltageLevel)); } - /** - * Gets a pair of IedName and LDevice inst from Substation LNodes for LN0 type object - * @return a pair of Ied name and LDevice inst attributes - */ - public List> getIedAndLDeviceNamesForLN0FromLNode() { - return streamVoltageLevelAdapters() - .flatMap(VoltageLevelAdapter::streamBayAdapters) - .flatMap(BayAdapter::streamFunctionAdapters) - .flatMap(functionAdapter -> functionAdapter.getCurrentElem().getLNode().stream()) - .filter(tlNode -> tlNode.getLnClass().contains(TLLN0Enum.LLN_0.value())) - .map(tlNode -> Pair.of(tlNode.getIedName(), tlNode.getLdInst())) - .collect(Collectors.toList()); - } - } diff --git a/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/SclServiceTest.java b/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/SclServiceTest.java index dafaf271a..3f164531c 100644 --- a/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/SclServiceTest.java +++ b/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/SclServiceTest.java @@ -9,9 +9,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtendWith; import org.junit.jupiter.params.ParameterizedTest; -import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.CsvSource; -import org.junit.jupiter.params.provider.MethodSource; import org.lfenergy.compas.scl2007b4.model.*; import org.lfenergy.compas.sct.commons.dto.*; import org.lfenergy.compas.sct.commons.exception.ScdException; @@ -21,7 +19,6 @@ import org.lfenergy.compas.sct.commons.scl.ldevice.LDeviceAdapter; import org.lfenergy.compas.sct.commons.scl.ln.LN0Adapter; import org.lfenergy.compas.sct.commons.scl.ln.LNAdapter; -import org.lfenergy.compas.sct.commons.testhelpers.MarshallerWrapper; import org.lfenergy.compas.sct.commons.testhelpers.SclTestMarshaller; import org.mockito.InjectMocks; import org.mockito.junit.jupiter.MockitoExtension; @@ -29,7 +26,6 @@ import java.util.List; import java.util.Optional; import java.util.UUID; -import java.util.stream.Stream; import static org.assertj.core.api.Assertions.assertThat; import static org.assertj.core.api.Assertions.assertThatThrownBy; @@ -46,60 +42,6 @@ class SclServiceTest { @InjectMocks SclService sclService; - private static Stream sclProviderMissingRequiredObjects() { - SCL scl1 = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_KO_MissingBeh.scd"); - SCL scl2 = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivate.scd"); - SCL scl3 = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivateAttribute.scd"); - SCL scl4 = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_KO_MissingMod.scd"); - Tuple[] scl1Errors = new Tuple[]{Tuple.tuple("The LDevice doesn't have a DO @name='Beh' OR its associated DA@fc='ST' AND DA@name='stVal'", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0")}; - Tuple[] scl2Errors = new Tuple[]{Tuple.tuple("The LDevice doesn't have a Private compas:LDevice.", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0")}; - Tuple[] scl3Errors = new Tuple[]{Tuple.tuple("The Private compas:LDevice doesn't have the attribute 'LDeviceStatus'", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0")}; - Tuple[] scl4Errors = new Tuple[]{Tuple.tuple("The LDevice doesn't have a DO @name='Mod'", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0")}; - return Stream.of( - Arguments.of("MissingDOBeh", scl1, scl1Errors), - Arguments.of("MissingLDevicePrivate", scl2, scl2Errors), - Arguments.of("MissingLDevicePrivateAttribute", scl3, scl3Errors), - Arguments.of("MissingDOMod", scl4, scl4Errors) - ); - } - - private static Stream sclProviderBasedLDeviceStatus() { - SCL scl1 = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_LD_STATUS_ACTIVE.scd"); - SCL scl2 = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_LD_STATUS_UNTESTED.scd"); - SCL scl3 = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test1_LD_STATUS_INACTIVE.scd"); - Tuple[] scl1Errors = new Tuple[]{Tuple.tuple("The LDevice cannot be set to 'off' but has not been selected into SSD.", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0"), - Tuple.tuple("The LDevice cannot be set to 'on' but has been selected into SSD.", - "/SCL/IED[@name=\"IedName2\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0"), - Tuple.tuple("The LDevice cannot be activated or desactivated because its BehaviourKind Enum contains NOT 'on' AND NOT 'off'.", - "/SCL/IED[@name=\"IedName3\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0" - )}; - Tuple[] scl2Errors = new Tuple[]{Tuple.tuple("The LDevice cannot be set to 'off' but has not been selected into SSD.", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0"), - Tuple.tuple("The LDevice cannot be set to 'on' but has been selected into SSD.", - "/SCL/IED[@name=\"IedName2\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0"), - Tuple.tuple("The LDevice cannot be activated or desactivated because its BehaviourKind Enum contains NOT 'on' AND NOT 'off'.", - "/SCL/IED[@name=\"IedName3\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0" - )}; - Tuple[] scl3Errors = new Tuple[]{Tuple.tuple("The LDevice is not qualified into STD but has been selected into SSD.", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0"), - Tuple.tuple("The LDevice cannot be set to 'on' but has been selected into SSD.", - "/SCL/IED[@name=\"IedName2\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0"), - Tuple.tuple("The LDevice cannot be activated or desactivated because its BehaviourKind Enum contains NOT 'on' AND NOT 'off'.", - "/SCL/IED[@name=\"IedName3\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0" - )}; - return Stream.of( - Arguments.of("ACTIVE", scl1, scl1Errors), - Arguments.of("UNTESTED", scl2, scl2Errors), - Arguments.of("INACTIVE", scl3, scl3Errors) - ); - } - - @Test void addHistoryItem_should_add_history_elements() throws ScdException { //Given @@ -175,7 +117,6 @@ void addSubnetworks_whenNoCommunicationTagInIcd_should_not_add_subnetwork() { @Test void addSubnetworks_shouldNotUpdateScd_when_noCommunicationInSTDExist() { //Givens - SCL initial = SclTestMarshaller.getSCLFromFile("/scl_update_communication/scd_without_communication.xml"); SCL scd = SclTestMarshaller.getSCLFromFile("/scl_update_communication/scd_without_communication.xml"); SCL icd = SclTestMarshaller.getSCLFromFile("/scl_update_communication/std_without_communication.xml"); assertThat(scd.getCommunication()).isNull(); @@ -396,138 +337,6 @@ void importSTDElementsInSCD_whenNoSTDMatch_shouldThrowException() { .hasMessage("There is no STD file found corresponding to headerId = f8dbc8c1-2db7-4652-a9d6-0b414bdeccfa, headerVersion = 01.00.00, headerRevision = 01.00.00 and ICDSystemVersionUUID = IED4d4fe1a8cda64cf88a5ee4176a1a0eef"); } - @ParameterizedTest(name = "{0}") - @MethodSource("sclProviderMissingRequiredObjects") - void updateLDeviceStatus_whenMissingRequiredObject_shouldReturnReportWithError(String testCase, SCL scl, Tuple... errors) { - // Given - assertThat(getLDeviceStatusValue(scl, "IedName1", "LDSUIED")).isPresent(); - assertThat(getLDeviceStatusValue(scl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("off"); - String before = MarshallerWrapper.marshall(scl); - // When - List sclReportItems = sclService.updateLDeviceStatus(scl); - // Then - String after = MarshallerWrapper.marshall(scl); - assertThat(sclReportItems.stream().noneMatch(SclReportItem::isError)).isFalse(); - assertThat(sclReportItems) - .hasSize(1) - .extracting(SclReportItem::message, SclReportItem::xpath) - .containsExactly(errors); - assertThat(getLDeviceStatusValue(scl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("off"); - assertThat(before).isEqualTo(after); - } - - @ParameterizedTest(name = "{0}") - @MethodSource("sclProviderBasedLDeviceStatus") - void updateLDeviceStatus_whenLDeviceStatusActiveOrUntestedOrInactive_shouldReturnReportWithError(String testCase, SCL scl, Tuple... errors) { - // Given - assertThat(getLDeviceStatusValue(scl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("off"); - assertThat(getLDeviceStatusValue(scl, "IedName2", "LDSUIED").get().getValue()).isEqualTo("on"); - assertThat(getLDeviceStatusValue(scl, "IedName3", "LDSUIED")).isEmpty(); - String before = MarshallerWrapper.marshall(scl); - // When - List sclReportItems = sclService.updateLDeviceStatus(scl); - // Then - String after = MarshallerWrapper.marshall(scl); - assertThat(sclReportItems.stream().noneMatch(SclReportItem::isError)).isFalse(); - assertThat(sclReportItems) - .hasSize(3) - .extracting(SclReportItem::message, SclReportItem::xpath) - .containsExactly(errors); - assertThat(getLDeviceStatusValue(scl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("off"); - assertThat(getLDeviceStatusValue(scl, "IedName2", "LDSUIED").get().getValue()).isEqualTo("on"); - assertThat(getLDeviceStatusValue(scl, "IedName3", "LDSUIED")).isEmpty(); - assertThat(before).isEqualTo(after); - } - - @Test - void updateLDeviceStatus_whenAllLDeviceInactive_shouldReturnReportWithError() { - // Given - SCL scl = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test2_LD_STATUS_INACTIVE.scd"); - assertThat(getLDeviceStatusValue(scl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("off"); - assertThat(getLDeviceStatusValue(scl, "IedName2", "LDSUIED").get().getValue()).isEqualTo("on"); - assertThat(getLDeviceStatusValue(scl, "IedName3", "LDSUIED")).isEmpty(); - // When - List sclReportItems = sclService.updateLDeviceStatus(scl); - // Then - assertThat(sclReportItems.stream().noneMatch(SclReportItem::isError)).isFalse(); - assertThat(sclReportItems) - .hasSize(2) - .extracting(SclReportItem::message, SclReportItem::xpath) - .containsExactly(Tuple.tuple("The LDevice cannot be set to 'off' but has not been selected into SSD.", - "/SCL/IED[@name=\"IedName1\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0"), - Tuple.tuple("The LDevice is not qualified into STD but has been selected into SSD.", - "/SCL/IED[@name=\"IedName2\"]/AccessPoint/Server/LDevice[@inst=\"LDSUIED\"]/LN0")); - assertThat(getLDeviceStatusValue(scl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("off"); - assertThat(getLDeviceStatusValue(scl, "IedName2", "LDSUIED").get().getValue()).isEqualTo("on"); - assertThat(getLDeviceStatusValue(scl, "IedName3", "LDSUIED")).isPresent(); - assertThat(getLDeviceStatusValue(scl, "IedName3", "LDSUIED").get().getValue()).isEqualTo("off"); - } - - @Test - void updateLDeviceStatus_shouldReturnUpdatedFile() { - // Given - SCL givenScl = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_Template.scd"); - assertThat(getLDeviceStatusValue(givenScl, "IedName1", "LDSUIED")).isPresent(); - assertThat(getLDeviceStatusValue(givenScl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("off"); - assertThat(getLDeviceStatusValue(givenScl, "IedName2", "LDSUIED")).isPresent(); - assertThat(getLDeviceStatusValue(givenScl, "IedName2", "LDSUIED").get().getValue()).isEqualTo("on"); - assertThat(getLDeviceStatusValue(givenScl, "IedName3", "LDSUIED")).isEmpty(); - // When - List sclReportItems = sclService.updateLDeviceStatus(givenScl); - // Then - assertThat(sclReportItems.stream().noneMatch(SclReportItem::isError)).isTrue(); - assertThat(getLDeviceStatusValue(givenScl, "IedName1", "LDSUIED")).isPresent(); - assertThat(getLDeviceStatusValue(givenScl, "IedName1", "LDSUIED").get().getValue()).isEqualTo("on"); - assertThat(getLDeviceStatusValue(givenScl, "IedName2", "LDSUIED")).isPresent(); - assertThat(getLDeviceStatusValue(givenScl, "IedName2", "LDSUIED").get().getValue()).isEqualTo("off"); - assertThat(getLDeviceStatusValue(givenScl, "IedName3", "LDSUIED")).isPresent(); - assertThat(getLDeviceStatusValue(givenScl, "IedName3", "LDSUIED").get().getValue()).isEqualTo("off"); - } - - @Test - void updateLDeviceStatus_when_DAI_Mod_DO_stVal_whateverIsUpdatableOrNot_shouldReturnUpdatedFile() { - // Given - SCL givenScl = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue_165_enhance_68_Test_Dai_Updatable.scd"); - assertThat(getLDeviceStatusValue(givenScl, "IedName1", "LDSUIED")) - .map(TVal::getValue) - .hasValue("off"); - assertThat(getLDeviceStatusValue(givenScl, "IedName2", "LDSUIED")) - .map(TVal::getValue) - .hasValue("on"); - assertThat(getLDeviceStatusValue(givenScl, "IedName3", "LDSUIED")) - .map(TVal::getValue) - .isNotPresent(); - assertThat(getLDeviceStatusValue(givenScl, "IedName4", "LDSUIED")) - .map(TVal::getValue) - .hasValue("on"); - assertThat(getLDeviceStatusValue(givenScl, "IedName5", "LDSUIED")) - .map(TVal::getValue) - .hasValue("on"); - // When - List sclReportItems = sclService.updateLDeviceStatus(givenScl); - // Then - assertThat(sclReportItems.stream().noneMatch(SclReportItem::isError)).isTrue(); - assertThat(getLDeviceStatusValue(givenScl, "IedName1", "LDSUIED")) - .map(TVal::getValue) - .hasValue("on"); - assertThat(getLDeviceStatusValue(givenScl, "IedName2", "LDSUIED")) - .map(TVal::getValue) - .hasValue("off"); - assertThat(getLDeviceStatusValue(givenScl, "IedName3", "LDSUIED")) - .map(TVal::getValue) - .hasValue("off"); - assertThat(getLDeviceStatusValue(givenScl, "IedName4", "LDSUIED")) - .map(TVal::getValue) - .hasValue("off"); - assertThat(getLDeviceStatusValue(givenScl, "IedName5", "LDSUIED")) - .map(TVal::getValue) - .hasValue("off"); - } - - private Optional getLDeviceStatusValue(SCL scl, String iedName, String ldInst) { - return getValFromDaiName(scl, iedName, ldInst, "Mod", "stVal"); - } - @ParameterizedTest(name = "{0}") @CsvSource({ "Test update setSrcRef Value,LD_WITH_1_InRef,InRef2,setSrcRef,IED_NAME1LD_WITH_1_InRef/PRANCR1.Do11.sdo11", diff --git a/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/scl/ldevice/LDeviceActivationTest.java b/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/scl/ldevice/LDeviceActivationTest.java deleted file mode 100644 index 8858ed3ac..000000000 --- a/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/scl/ldevice/LDeviceActivationTest.java +++ /dev/null @@ -1,199 +0,0 @@ -// SPDX-FileCopyrightText: 2022 RTE FRANCE -// -// SPDX-License-Identifier: Apache-2.0 - -package org.lfenergy.compas.sct.commons.scl.ldevice; - -import org.apache.commons.lang3.tuple.Pair; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.params.ParameterizedTest; -import org.junit.jupiter.params.provider.CsvSource; -import org.junit.jupiter.params.provider.ValueSource; -import org.lfenergy.compas.scl2007b4.model.TCompasLDeviceStatus; - -import java.util.List; -import java.util.Set; - -import static org.assertj.core.api.Assertions.assertThat; - -class LDeviceActivationTest { - - @ParameterizedTest - @ValueSource(strings = {"ACTIVE", "UNTESTED"}) - void checkLDeviceActivationStatus_shouldReturnNoError_when_LDeviceStatusACTIVE_Or_UNTESTED_And_Contains_ON_And_LDeviceReferencedINLNode(String lDeviceStatus) { - // Given - List> iedNameLdInstList = List.of(Pair.of("iedName1", "ldInst1")); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("on"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.fromValue(lDeviceStatus), Set.of("on")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isTrue(); - assertThat(lDeviceActivation.getErrorMessage()).isNull(); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("on"); - } - - @ParameterizedTest - @ValueSource(strings = {"ACTIVE", "UNTESTED"}) - void checkLDeviceActivationStatus_shouldReturnError_when_LDeviceStatusACTIVE_Or_UNTESTED_And_Contains_ON_And_NotLDeviceReferencedINLNode(String lDeviceStatus) { - // Given - List> iedNameLdInstList = List.of(); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("on"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst2", TCompasLDeviceStatus.valueOf(lDeviceStatus), Set.of("on")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isFalse(); - assertThat(lDeviceActivation.getErrorMessage()).isEqualTo("The LDevice cannot be set to 'off' but has not been selected into SSD."); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("on"); - } - - @ParameterizedTest - @ValueSource(strings = {"ACTIVE", "UNTESTED"}) - void checkLDeviceActivationStatus_shouldReturnError_when_LDeviceStatusACTIVE_Or_UNTESTED_And_Contains_OFF_And_LDeviceReferencedINLNode(String lDeviceStatus) { - // Given - List> iedNameLdInstList = List.of(Pair.of("iedName1", "ldInst1")); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("off"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.valueOf(lDeviceStatus), Set.of("off")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isFalse(); - assertThat(lDeviceActivation.getErrorMessage()).isEqualTo( - "The LDevice cannot be set to 'on' but has been selected into SSD."); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("off"); - } - - @ParameterizedTest - @ValueSource(strings = {"ACTIVE", "UNTESTED"}) - void checkLDeviceActivationStatus_shouldReturnNoError_when_LDeviceStatusACTIVE_Or_UNTESTED_And_Contains_OFF_And_NotLDeviceReferencedINLNode(String lDeviceStatus) { - // Given - List> iedNameLdInstList = List.of(); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("on"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.valueOf(lDeviceStatus), Set.of("off")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isTrue(); - assertThat(lDeviceActivation.getErrorMessage()).isNull(); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("off"); - } - - @ParameterizedTest - @ValueSource(strings = {"ACTIVE", "UNTESTED"}) - void checkLDeviceActivationStatus_shouldReturnNoError_when_LDeviceStatusACTIVE_Or_UNTESTED_And_Contains_ON_And_OFF_And_LDeviceReferencedINLNode(String lDeviceStatus) { - // Given - List> iedNameLdInstList = List.of(Pair.of("iedName1", "ldInst1")); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("off"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.valueOf(lDeviceStatus), Set.of("on", "off")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isTrue(); - assertThat(lDeviceActivation.getErrorMessage()).isNull(); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("on"); - } - - @ParameterizedTest - @ValueSource(strings = {"ACTIVE", "UNTESTED"}) - void checkLDeviceActivationStatus_shouldReturnNoError_when_LDeviceStatusACTIVE_Or_UNTESTED_And_Contains_ON_And_OFF_And_NotLDeviceReferencedINLNode(String lDeviceStatus) { - // Given - List> iedNameLdInstList = List.of(); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("off"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst2", TCompasLDeviceStatus.valueOf(lDeviceStatus), Set.of("on", "off")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isTrue(); - assertThat(lDeviceActivation.getErrorMessage()).isNull(); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("off"); - } - - @ParameterizedTest - @CsvSource(value = {"ACTIVE; iedName1; ldInst1","INACTIVE; iedName1; ldInst1", "UNTESTED; iedName1; ldInst1", "ACTIVE;;","INACTIVE;;", "UNTESTED;;"}, delimiter = ';') - void checkLDeviceActivationStatus_shouldReturnError_when_Contains_Not_ON_Nor_OFF(String lDeviceStatus, String iedName, String ldInst) { - // Given - List> iedNameLdInstList = List.of(Pair.of(iedName, ldInst)); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("off"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.valueOf(lDeviceStatus), Set.of()); - // Then - assertThat(lDeviceActivation.isUpdatable()).isFalse(); - assertThat(lDeviceActivation.getErrorMessage()).isEqualTo( - "The LDevice cannot be activated or desactivated because its BehaviourKind Enum contains NOT 'on' AND NOT 'off'."); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("off"); - } - - @Test - void checkLDeviceActivationStatus_shouldReturnError_when_LDeviceStatusINACTIVE_And_Contains_ON_And_LDeviceReferencedINLNode() { - // Given - List> iedNameLdInstList = List.of(Pair.of("iedName1", "ldInst1")); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("on"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.INACTIVE, Set.of("on")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isFalse(); - assertThat(lDeviceActivation.getErrorMessage()).isEqualTo("The LDevice is not qualified into STD but has been selected into SSD."); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("on"); - } - - @Test - void checkLDeviceActivationStatus_shouldReturnNoError_when_LDeviceStatusINACTIVE_And_Contains_ON_And_OFF_And_NotLDeviceReferencedINLNode() { - // Given - List> iedNameLdInstList = List.of(); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("on"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.INACTIVE, Set.of("on", "off")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isTrue(); - assertThat(lDeviceActivation.getErrorMessage()).isNull(); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("off"); - } - - @Test - void checkLDeviceActivationStatus_shouldReturnError_when_LDeviceStatusINACTIVE_And_Contains_ON_And_NotLDeviceReferencedINLNode() { - // Given - List> iedNameLdInstList = List.of(); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("on"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.INACTIVE, Set.of("on")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isFalse(); - assertThat(lDeviceActivation.getErrorMessage()).isEqualTo("The LDevice cannot be set to 'off' but has not been selected into SSD."); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("on"); - } - - @Test - void checkLDeviceActivationStatus_shouldReturnNoError_when_LDeviceStatusINACTIVE_And_Contains_OFF_And_NotLDeviceReferencedINLNode() { - // Given - List> iedNameLdInstList = List.of(); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("on"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.INACTIVE, Set.of("off")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isTrue(); - assertThat(lDeviceActivation.getErrorMessage()).isNull(); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("off"); - } - - @Test - void checkLDeviceActivationStatus_shouldReturnError_when_LDeviceStatusINACTIVE_And_Contains_ON_And_OFF_And_LDeviceReferencedINLNode() { - // Given - List> iedNameLdInstList = List.of(Pair.of("iedName1", "ldInst1")); - LDeviceActivation lDeviceActivation = new LDeviceActivation(iedNameLdInstList); - lDeviceActivation.setNewVal("off"); - // When - lDeviceActivation.checkLDeviceActivationStatus("iedName1", "ldInst1", TCompasLDeviceStatus.INACTIVE, Set.of("on", "off")); - // Then - assertThat(lDeviceActivation.isUpdatable()).isFalse(); - assertThat(lDeviceActivation.getErrorMessage()).isEqualTo( - "The LDevice is not qualified into STD but has been selected into SSD."); - assertThat(lDeviceActivation.getNewVal()).isEqualTo("off"); - } - -} \ No newline at end of file diff --git a/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapterTest.java b/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapterTest.java index f7d1abdc2..1f7edd2f9 100644 --- a/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapterTest.java +++ b/sct-commons/src/test/java/org/lfenergy/compas/sct/commons/scl/sstation/SubstationAdapterTest.java @@ -4,7 +4,6 @@ package org.lfenergy.compas.sct.commons.scl.sstation; -import org.apache.commons.lang3.tuple.Pair; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.lfenergy.compas.scl2007b4.model.SCL; @@ -12,9 +11,6 @@ import org.lfenergy.compas.scl2007b4.model.TSubstation; import org.lfenergy.compas.scl2007b4.model.TVoltageLevel; import org.lfenergy.compas.sct.commons.scl.SclRootAdapter; -import org.lfenergy.compas.sct.commons.testhelpers.SclTestMarshaller; - -import java.util.List; import static org.assertj.core.api.Assertions.assertThat; import static org.assertj.core.api.Assertions.assertThatThrownBy; @@ -93,19 +89,4 @@ void addPrivate_with_type_and_source_should_create_Private() { assertThat(substationAdapter.getCurrentElem().getPrivate()).isNotEmpty(); } - - @Test - void getIedAndLDeviceNamesForLN0FromLNode_whenLNodeContainsLN0_shouldReturnListOf1Pair() { - // Given - SCL scl = SclTestMarshaller.getSCLFromFile("/scd-refresh-lnode/issue68_Test_Template.scd"); - SclRootAdapter sclRootAdapter = new SclRootAdapter(scl); - substationAdapter = sclRootAdapter.getSubstationAdapter(); - // When - List> iedNameLdInstList = substationAdapter.getIedAndLDeviceNamesForLN0FromLNode(); - // Then - assertThat(iedNameLdInstList) - .hasSize(1) - .containsExactly(Pair.of("IedName1", "LDSUIED")); - } - } diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test1_LD_STATUS_INACTIVE.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test1_LD_STATUS_INACTIVE.scd deleted file mode 100644 index 33fc9cba8..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test1_LD_STATUS_INACTIVE.scd +++ /dev/null @@ -1,247 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
- -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
- -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - on - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - on - blocked - test - test/blocked - - - off - blocked - test - test/blocked - - - blocked - test - test/blocked - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test2_LD_STATUS_INACTIVE.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test2_LD_STATUS_INACTIVE.scd deleted file mode 100644 index 72b928c71..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test2_LD_STATUS_INACTIVE.scd +++ /dev/null @@ -1,240 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
- -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
- -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - on - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - on - blocked - test - test/blocked - - - on - off - blocked - test - test/blocked - - - on - off - blocked - test - test/blocked - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_Dai_Not_Updatable.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_Dai_Not_Updatable.scd deleted file mode 100644 index 730ca6fd7..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_Dai_Not_Updatable.scd +++ /dev/null @@ -1,223 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
- -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
- -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - on - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - on - off - blocked - test - test/blocked - - - on - off - blocked - test - test/blocked - - - on - off - blocked - test - test/blocked - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingBeh.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingBeh.scd deleted file mode 100644 index 9e88bb19e..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingBeh.scd +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - - - - - - - - - - - - - blocked - test - test/blocked - off - on - - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivate.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivate.scd deleted file mode 100644 index 49cb8aac5..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivate.scd +++ /dev/null @@ -1,122 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - - - - - - - - - - - - - - blocked - test - test/blocked - off - on - - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivateAttribute.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivateAttribute.scd deleted file mode 100644 index b592f569d..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingLDevicePrivateAttribute.scd +++ /dev/null @@ -1,125 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - - - - - - - - - - - - - - blocked - test - test/blocked - off - on - - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingMod.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingMod.scd deleted file mode 100644 index 27b6c193d..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_KO_MissingMod.scd +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - - - - - - - - - - - - - blocked - test - test/blocked - off - on - - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_LD_STATUS_ACTIVE.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_LD_STATUS_ACTIVE.scd deleted file mode 100644 index 87ca28bf1..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_LD_STATUS_ACTIVE.scd +++ /dev/null @@ -1,237 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
- -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
- -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - on - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - on - blocked - test - test/blocked - - - off - blocked - test - test/blocked - - - blocked - test - test/blocked - - -
diff --git a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_LD_STATUS_UNTESTED.scd b/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_LD_STATUS_UNTESTED.scd deleted file mode 100644 index c6f31cdb5..000000000 --- a/sct-commons/src/test/resources/scd-refresh-lnode/issue68_Test_LD_STATUS_UNTESTED.scd +++ /dev/null @@ -1,237 +0,0 @@ - - - - - - - SCD - -
- - - -
- - - - - - 0 - - - - - - - - - - - - - - - - - - - - - - - -
-

00000001

-
-
- -
-

00000001

-
-
-
- - -
-

Adresse IP du serveur Syslog

-
-
- -
-

Adresse IP du serveur Syslog

-
-
-
-
- - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - off - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - on - - - - - - - - - - - SAMU - SAMU - - - - - - - - - - - - - - - - - 01.00.000 - - - 01.00.000 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - on - blocked - test - test/blocked - - - off - blocked - test - test/blocked - - - blocked - test - test/blocked - - -