Skip to content
This repository has been archived by the owner on Nov 18, 2022. It is now read-only.

Commit

Permalink
Bump powsybl-core to 5.0.0-RC1 (#98)
Browse files Browse the repository at this point in the history
* Bump powsybl-core to 5.0.0-RC1
* Update network loading/reading
* Update unit test following new bus definition
* Fix disconnected 3wt edges and update test references

Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
  • Loading branch information
flo-dup authored Nov 4, 2022
1 parent 5bac9ab commit 4ea95ba
Show file tree
Hide file tree
Showing 36 changed files with 38 additions and 43 deletions.
7 changes: 1 addition & 6 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
**/generated/**/*
</sonar.exclusions>

<powsybl-core.version>4.10.0</powsybl-core.version>
<powsybl-core.version>5.0.0-RC1</powsybl-core.version>
<powsybl-olf.version>0.23.0</powsybl-olf.version>
<junit-jupiter.version>5.8.1</junit-jupiter.version>
<maven.compiler.source>11</maven.compiler.source>
Expand Down Expand Up @@ -117,11 +117,6 @@
<artifactId>powsybl-iidm-impl</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.powsybl</groupId>
<artifactId>powsybl-iidm-xml-converter</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.powsybl</groupId>
<artifactId>powsybl-ieee-cdf-converter</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/nominalStyle.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
.nad-branch-edges circle {stroke: var(--nad-vl-color, lightgrey); stroke-width: 0.05; fill: none}
.nad-3wt-edges polyline {stroke: var(--nad-vl-color, lightgrey); stroke-width: 0.05; fill: none}
.nad-text-edges {stroke: black; stroke-width: 0.02; stroke-dasharray: .03,.05}
.nad-branch-edges .nad-disconnected polyline {stroke-dasharray: .1,.1}
.nad-branch-edges .nad-disconnected polyline, .nad-3wt-edges .nad-disconnected polyline {stroke-dasharray: .1,.1}
.nad-vl-nodes circle, .nad-vl-nodes path {fill: var(--nad-vl-color, lightblue)}
.nad-vl-nodes circle.nad-unknown-busnode {stroke: lightgrey; stroke-width: 0.05; stroke-dasharray: .05,.05; fill: none}
.nad-hvdc-edge polyline.nad-hvdc {stroke: grey; stroke-width: 0.2}
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/topologicalStyle.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
.nad-branch-edges circle {stroke: var(--nad-vl-color, lightgrey); stroke-width: 0.05; fill: none}
.nad-3wt-edges polyline {stroke: var(--nad-vl-color, lightgrey); stroke-width: 0.05; fill: none}
.nad-text-edges {stroke: black; stroke-width: 0.02; stroke-dasharray: .03,.05}
.nad-branch-edges .nad-disconnected polyline {stroke-dasharray: .1,.1}
.nad-branch-edges .nad-disconnected polyline, .nad-3wt-edges .nad-disconnected polyline {stroke-dasharray: .1,.1}
.nad-vl-nodes circle, .nad-vl-nodes path {fill: var(--nad-vl-color, lightgrey)}
.nad-vl-nodes circle.nad-unknown-busnode {stroke: var(--nad-vl-color, #808080); stroke-width: 0.05; stroke-dasharray: .05,.05; fill: none}
.nad-hvdc-edge polyline.nad-hvdc {stroke: grey; stroke-width: 0.2}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
package com.powsybl.nad.svg;

import com.powsybl.ieeecdf.converter.IeeeCdfNetworkFactory;
import com.powsybl.iidm.import_.Importers;
import com.powsybl.iidm.network.Connectable;
import com.powsybl.iidm.network.Network;
import com.powsybl.iidm.network.Terminal;
Expand Down Expand Up @@ -101,21 +100,21 @@ void testIEEE24() {

@Test
void testEurope() {
Network network = Importers.loadNetwork("simple-eu.uct", getClass().getResourceAsStream("/simple-eu.uct"));
Network network = Network.read("simple-eu.uct", getClass().getResourceAsStream("/simple-eu.uct"));
LoadFlow.run(network);
assertEquals(toString("/simple-eu.svg"), generateSvgString(network, "/simple-eu.svg"));
}

@Test
void testEuropeLoopAperture80() {
Network network = Importers.loadNetwork("simple-eu.uct", getClass().getResourceAsStream("/simple-eu.uct"));
Network network = Network.read("simple-eu.uct", getClass().getResourceAsStream("/simple-eu.uct"));
getSvgParameters().setLoopEdgesAperture(80);
assertEquals(toString("/simple-eu-loop80.svg"), generateSvgString(network, "/simple-eu-loop80.svg"));
}

@Test
void testEuropeLoopAperture100() {
Network network = Importers.loadNetwork("simple-eu.uct", getClass().getResourceAsStream("/simple-eu.uct"));
Network network = Network.read("simple-eu.uct", getClass().getResourceAsStream("/simple-eu.uct"));
getSvgParameters().setLoopEdgesAperture(100);
assertEquals(toString("/simple-eu-loop100.svg"), generateSvgString(network, "/simple-eu-loop100.svg"));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ void test3wt() {
void testDisconnected3wt() {
Network network = ThreeWindingsTransformerNetworkFactory.create();
network.getThreeWindingsTransformer("3WT").getTerminal(ThreeWindingsTransformer.Side.TWO).disconnect();
network.getLoad("LOAD_33").remove();
assertEquals(toString("/3wt_disconnected.svg"), generateSvgString(network, "/3wt_disconnected.svg"));
}

Expand Down
2 changes: 1 addition & 1 deletion src/test/resources/3wt.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/3wt_disconnected.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/3wt_partial.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_118_bus.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_118_bus_partial.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_118_bus_partial_non_connected.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_14_bus.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_14_bus_disconnection.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_14_bus_fictitious.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_14_bus_text_nodes.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_14_id_prefixed.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_24_bus.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_30_bus.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/IEEE_57_bus.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/current_limits.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/diamond-spring-repulsion-factor-0.0.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/diamond-spring-repulsion-factor-0.2.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/edge_info_double_labels.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/edge_info_missing_label.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/edge_info_perpendicular_label.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/test/resources/edge_info_shift.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 4ea95ba

Please sign in to comment.