Skip to content

Commit

Permalink
Add SWE CNE tests for angle values (#966)
Browse files Browse the repository at this point in the history
Signed-off-by: Peter Mitri <peter.mitri@rte-france.com>
Co-authored-by: phiedw <philippe.e16@hotmail.fr>
Signed-off-by: belthlemar <martin.belthle@rte-france.com>
  • Loading branch information
2 people authored and MartinBelthle committed May 28, 2024
1 parent 06ce692 commit 7b9e9de
Show file tree
Hide file tree
Showing 4 changed files with 502 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -275,3 +275,29 @@ Feature: US 12.15: export different reason per perimeter in SWE CNE
When I import data at "2021-04-02 05:00"
And I export SWE CNE
Then the exported CNE file is the same as "epic12/ExpectedCNE_12_15_4.xml"

@fast @cne-export @mock
Scenario: US 12.15.5: CNE export with angles
# Copy of 12.15.4 with extra angle CNEC and extra angle values in RAO result
# Expected CNE is the same as 12.5.4 with the extra angle value information
Given network file is "epic12/nordic32.xiidm"
Given crac file is "epic12/CIM_12_15_5.xml"
Given crac creation parameters file is "epic12/CimCracCreationParameters_MonitorLeftSide.json"
Given configuration file is "epic12/raoParametersSweIDCC_minObjectiveDisabled2P.json"
Given RaoResult file is "epic12/RaoResult_12_15_5.json"
When I import data at "2021-04-02 05:00"
And I export SWE CNE
Then the exported CNE file is the same as "epic12/ExpectedCNE_12_15_5.xml"

@fast @cne-export @mock
Scenario: US 12.15.6: CNE export with angles, no angle results
# Copy of 12.15.4 with extra angle CNEC but no angle values in RAO result
# Should not fail. Should instead skip angle CNECs, thus expected CNE is the same as 12.5.4
Given network file is "epic12/nordic32.xiidm"
Given crac file is "epic12/CIM_12_15_5.xml"
Given crac creation parameters file is "epic12/CimCracCreationParameters_MonitorLeftSide.json"
Given configuration file is "epic12/raoParametersSweIDCC_minObjectiveDisabled2P.json"
Given RaoResult file is "epic12/RaoResult_12_15_4.json"
When I import data at "2021-04-02 05:00"
And I export SWE CNE
Then the exported CNE file is the same as "epic12/ExpectedCNE_12_15_4.xml"
147 changes: 147 additions & 0 deletions tests/src/test/resources/files/cne/epic12/ExpectedCNE_12_15_5.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<CriticalNetworkElement_MarketDocument xsi:schemaLocation="iec62325-451-n-cne_v2_3.xsd" xmlns="urn:iec62325.351:tc57wg16:451-n:cnedocument:2:3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<mRID>documentId</mRID>
<revisionNumber>3</revisionNumber>
<type>B06</type>
<process.processType>A48</process.processType>
<sender_MarketParticipant.mRID codingScheme="A01">senderId</sender_MarketParticipant.mRID>
<sender_MarketParticipant.marketRole.type>A44</sender_MarketParticipant.marketRole.type>
<receiver_MarketParticipant.mRID codingScheme="A01">receiverId</receiver_MarketParticipant.mRID>
<receiver_MarketParticipant.marketRole.type>A36</receiver_MarketParticipant.marketRole.type>
<createdDateTime>2023-01-30T15:58:09Z</createdDateTime>
<time_Period.timeInterval>
<start>2019-04-01T13:09Z</start>
<end>2019-04-01T14:09Z</end>
</time_Period.timeInterval>
<TimeSeries>
<mRID>CNE_RAO_CASTOR-TimeSeries-1</mRID>
<businessType>B54</businessType>
<curveType>A01</curveType>
<Period>
<timeInterval>
<start>2021-04-02T03:00Z</start>
<end>2021-04-02T04:00Z</end>
</timeInterval>
<resolution>PT60M</resolution>
<Point>
<position>1</position>
<Constraint_Series>
<mRID>1ddcfad-29bb-4ef1-828f-ed7065fd8928</mRID>
<businessType>B56</businessType>
</Constraint_Series>
<Constraint_Series>
<mRID>db4a7e0-dde6-4cc3-9ca5-4816d6f26491</mRID>
<businessType>B56</businessType>
<Contingency_Series>
<mRID>CO_N1012_N1014</mRID>
<name>CO_N1012_N1014</name>
</Contingency_Series>
</Constraint_Series>
<Constraint_Series>
<mRID>b893392-32ed-4569-8bcf-f022fb4c5933</mRID>
<businessType>B56</businessType>
<Contingency_Series>
<mRID>CO_N1012_N4012</mRID>
<name>CO_N1012_N4012</name>
</Contingency_Series>
</Constraint_Series>
<Constraint_Series>
<mRID>ab18126-3240-4a1d-808a-2884cd09875f</mRID>
<businessType>B57</businessType>
<Monitored_Series>
<mRID>CNE_N1011_N1013</mRID>
<name>CNE_N1011_N1013</name>
<RegisteredResource>
<mRID codingScheme="A02">N1011___-N1013___-1_AC</mRID>
<name>N1011_N1013</name>
<in_AggregateNode.mRID codingScheme="A02">N1011____VL</in_AggregateNode.mRID>
<out_AggregateNode.mRID codingScheme="A02">N1013____VL</out_AggregateNode.mRID>
<Measurements>
<measurementType>A01</measurementType>
<unitSymbol>AMP</unitSymbol>
<positiveFlowIn>A02</positiveFlowIn>
<analogValues.value>1076</analogValues.value>
</Measurements>
<Measurements>
<measurementType>A02</measurementType>
<unitSymbol>AMP</unitSymbol>
<positiveFlowIn>A02</positiveFlowIn>
<analogValues.value>1000</analogValues.value>
</Measurements>
</RegisteredResource>
</Monitored_Series>
</Constraint_Series>
<Constraint_Series>
<mRID>e1fc140-be92-4ed1-bf9a-befe09ab1553</mRID>
<businessType>B57</businessType>
<AdditionalConstraint_Series>
<mRID>AC-1</mRID>
<businessType>B87</businessType>
<name>Angle-Constraint</name>
<quantity.quantity>20.0</quantity.quantity>
</AdditionalConstraint_Series>
<Contingency_Series>
<mRID>CO_N1012_N1014</mRID>
<name>CO_N1012_N1014</name>
</Contingency_Series>
<Monitored_Series>
<mRID>CNE_N1013_N1014</mRID>
<name>CNE_N1013_N1014</name>
<RegisteredResource>
<mRID codingScheme="A02">N1013___-N1014___-1_AC</mRID>
<name>N1013_N1014</name>
<in_AggregateNode.mRID codingScheme="A02">N1013____VL</in_AggregateNode.mRID>
<out_AggregateNode.mRID codingScheme="A02">N1014____VL</out_AggregateNode.mRID>
<Measurements>
<measurementType>A01</measurementType>
<unitSymbol>AMP</unitSymbol>
<positiveFlowIn>A02</positiveFlowIn>
<analogValues.value>700</analogValues.value>
</Measurements>
<Measurements>
<measurementType>A13</measurementType>
<unitSymbol>AMP</unitSymbol>
<positiveFlowIn>A02</positiveFlowIn>
<analogValues.value>500</analogValues.value>
</Measurements>
</RegisteredResource>
</Monitored_Series>
</Constraint_Series>
<Constraint_Series>
<mRID>5ac608b-32a2-46da-b497-5eb07774e9cd</mRID>
<businessType>B57</businessType>
<Contingency_Series>
<mRID>CO_N1012_N4012</mRID>
<name>CO_N1012_N4012</name>
</Contingency_Series>
<Monitored_Series>
<mRID>CNE_N1013_N1014</mRID>
<name>CNE_N1013_N1014</name>
<RegisteredResource>
<mRID codingScheme="A02">N1013___-N1014___-1_AC</mRID>
<name>N1013_N1014</name>
<in_AggregateNode.mRID codingScheme="A02">N1013____VL</in_AggregateNode.mRID>
<out_AggregateNode.mRID codingScheme="A02">N1014____VL</out_AggregateNode.mRID>
<Measurements>
<measurementType>A01</measurementType>
<unitSymbol>AMP</unitSymbol>
<positiveFlowIn>A02</positiveFlowIn>
<analogValues.value>1919</analogValues.value>
</Measurements>
<Measurements>
<measurementType>A13</measurementType>
<unitSymbol>AMP</unitSymbol>
<positiveFlowIn>A02</positiveFlowIn>
<analogValues.value>500</analogValues.value>
</Measurements>
</RegisteredResource>
</Monitored_Series>
</Constraint_Series>
<Reason>
<code>Z03</code>
<text>Network is unsecure</text>
</Reason>
</Point>
</Period>
</TimeSeries>
</CriticalNetworkElement_MarketDocument>
168 changes: 168 additions & 0 deletions tests/src/test/resources/files/crac/epic12/CIM_12_15_5.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
<?xml version="1.0" encoding="UTF-8"?>
<CRAC_MarketDocument xmlns="urn:iec62325.351:tc57wg16:451-n:CRACdocument:2:3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:iec62325.351:tc57wg16:451-n:CRACdocument:2:3 iec62325-451-n-crac_v2_3.xsd">
<mRID>CORESO-20210402-SWECCD2-F011</mRID>
<revisionNumber>1</revisionNumber>
<type>B15</type>
<process.processType>A48</process.processType>
<sender_MarketParticipant.mRID codingScheme="A01">22XCORESO------S</sender_MarketParticipant.mRID>
<sender_MarketParticipant.marketRole.type>A36</sender_MarketParticipant.marketRole.type>
<receiver_MarketParticipant.mRID codingScheme="A01">10XES-REE------E</receiver_MarketParticipant.mRID>
<receiver_MarketParticipant.marketRole.type>A04</receiver_MarketParticipant.marketRole.type>
<createdDateTime>2021-03-31T15:02:00Z</createdDateTime>
<status>
<value>A42</value>
</status>
<time_Period.timeInterval>
<start>2021-04-01T22:00Z</start>
<end>2021-04-02T22:00Z</end>
</time_Period.timeInterval>
<domain.mRID codingScheme="A01">10YCB-FR-ES-PT-S</domain.mRID>
<TimeSeries>
<mRID>TimeSeries</mRID>
<businessType>B54</businessType>
<curveType>A03</curveType>
<in_Domain.mRID codingScheme="A01">10YES-REE------0</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YFR-RTE------C</out_Domain.mRID>
<Period>
<timeInterval>
<start>2021-04-01T22:00Z</start>
<end>2021-04-02T22:00Z</end>
</timeInterval>
<resolution>PT60M</resolution>
<Point>
<position>1</position>
<Series>
<mRID>CoList</mRID>
<businessType>B55</businessType>
<name>CoList</name>
<optimization_MarketObjectStatus.status>A52</optimization_MarketObjectStatus.status>
<Contingency_Series>
<mRID>CO_N1012_N4012</mRID>
<name>CO_N1012_N4012</name>
<RegisteredResource>
<mRID codingScheme="A02">N1012___-N4012___-1_PT</mRID>
<name>N1012_N4012</name>
<in_Domain.mRID codingScheme="A01">10YFR-RTE------C</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YFR-RTE------C</out_Domain.mRID>
</RegisteredResource>
</Contingency_Series>
<Contingency_Series>
<mRID>CO_N1012_N1014</mRID>
<name>CO_N1012_N1014</name>
<RegisteredResource>
<mRID codingScheme="A02">N1012___-N1014___-2_AC</mRID>
<name>N1012_N1014</name>
<in_Domain.mRID codingScheme="A01">10YFR-RTE------C</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YFR-RTE------C</out_Domain.mRID>
</RegisteredResource>
</Contingency_Series>
</Series>
<Series>
<mRID>MRList</mRID>
<businessType>B57</businessType>
<name>Monitored_Resources</name>
<optimization_MarketObjectStatus.status>A52</optimization_MarketObjectStatus.status>
<Monitored_Series>
<mRID>CNE_N1011_N1013</mRID>
<name>CNE_N1011_N1013</name>
<RegisteredResource>
<mRID codingScheme="A02">N1011___-N1013___-1_AC</mRID>
<name>N1011_N1013</name>
<in_Domain.mRID codingScheme="A01">10YFR-RTE------C</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YFR-RTE------C</out_Domain.mRID>
<Measurements>
<measurementType>A02</measurementType>
<unitSymbol>AMP</unitSymbol>
<analogValues.value>1000.0</analogValues.value>
</Measurements>
</RegisteredResource>
</Monitored_Series>
<Monitored_Series>
<mRID>CNE_N1013_N1014</mRID>
<name>CNE_N1013_N1014</name>
<RegisteredResource>
<mRID codingScheme="A02">N1013___-N1014___-1_AC</mRID>
<name>N1013_N1014</name>
<in_Domain.mRID codingScheme="A01">10YFR-RTE------C</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YFR-RTE------C</out_Domain.mRID>
<Measurements>
<measurementType>A13</measurementType>
<unitSymbol>AMP</unitSymbol>
<analogValues.value>500.0</analogValues.value>
</Measurements>
</RegisteredResource>
</Monitored_Series>
</Series>
<Series>
<mRID>PRAList</mRID>
<businessType>B56</businessType>
<name>PRAList</name>
<optimization_MarketObjectStatus.status>Z01</optimization_MarketObjectStatus.status>
<RemedialAction_Series>
<mRID>PRA_OPEN_N1011_N1013</mRID>
<name>PRA_OPEN_N1011_N1013</name>
<businessType>B59</businessType>
<applicationMode_MarketObjectStatus.status>A18</applicationMode_MarketObjectStatus.status>
<availability_MarketObjectStatus.status>A39</availability_MarketObjectStatus.status>
<RegisteredResource>
<mRID codingScheme="A02">N1011___-N1013___-1_AC</mRID>
<name>N1013_N1014</name>
<pSRType.psrType>A02</pSRType.psrType>
<in_Domain.mRID codingScheme="A01">10YPT-REN------W</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YPT-REN------W</out_Domain.mRID>
<marketObjectStatus.status>A21</marketObjectStatus.status>
</RegisteredResource>
</RemedialAction_Series>
</Series>
<Series>
<mRID>CRAList</mRID>
<businessType>B56</businessType>
<name>CRAList</name>
<optimization_MarketObjectStatus.status>Z01</optimization_MarketObjectStatus.status>
<AdditionalConstraint_Series>
<mRID>AC-1</mRID>
<businessType>B87</businessType>
<name>Angle-Constraint</name>
<measurement_Unit.name>DD</measurement_Unit.name>
<quantity.quantity>30</quantity.quantity>
<RegisteredResource>
<mRID codingScheme="A02">N4012____VL</mRID>
<name>ONE</name>
<marketObjectStatus.status>A47</marketObjectStatus.status>
</RegisteredResource>
<RegisteredResource>
<mRID codingScheme="A02">N4011____VL</mRID>
<name>TWO</name>
<marketObjectStatus.status>A46</marketObjectStatus.status>
</RegisteredResource>
</AdditionalConstraint_Series>
<Contingency_Series>
<mRID>CO_N1012_N1014</mRID>
<name>CO_N1012_N1014</name>
<RegisteredResource>
<mRID codingScheme="A02">N1012___-N1014___-2_AC</mRID>
<name>N1012_N1014</name>
<in_Domain.mRID codingScheme="A01">10YFR-RTE------C</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YFR-RTE------C</out_Domain.mRID>
</RegisteredResource>
</Contingency_Series>
<RemedialAction_Series>
<mRID>CRA_CLOSE_N1012_N4012</mRID>
<name>CRA_CLOSE_N1012_N4012</name>
<businessType>B59</businessType>
<applicationMode_MarketObjectStatus.status>A19</applicationMode_MarketObjectStatus.status>
<availability_MarketObjectStatus.status>A39</availability_MarketObjectStatus.status>
<RegisteredResource>
<mRID codingScheme="A02">N1012___-N4012___-1_PT</mRID>
<name>N1012_N4012</name>
<pSRType.psrType>A02</pSRType.psrType>
<in_Domain.mRID codingScheme="A01">10YPT-REN------W</in_Domain.mRID>
<out_Domain.mRID codingScheme="A01">10YPT-REN------W</out_Domain.mRID>
<marketObjectStatus.status>A22</marketObjectStatus.status>
</RegisteredResource>
</RemedialAction_Series>
</Series>
</Point>
</Period>
</TimeSeries>
</CRAC_MarketDocument>
Loading

0 comments on commit 7b9e9de

Please sign in to comment.