Skip to content

Commit

Permalink
test(st-storage): correct unit tests for ST Storages
Browse files Browse the repository at this point in the history
  • Loading branch information
laurent-laporte-pro committed Apr 23, 2024
1 parent 38cb653 commit 95a5ac5
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions tests/study/business/areas/test_st_storage_management.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ def test_get_all_storages__nominal_case(
"west": [
{
"id": "storage1",
"enabled": None,
"group": STStorageGroup.BATTERY,
"name": "Storage1",
"injectionNominalCapacity": 1500.0,
Expand All @@ -153,6 +154,7 @@ def test_get_all_storages__nominal_case(
},
{
"id": "storage2",
"enabled": None,
"group": STStorageGroup.PSP_CLOSED,
"name": "Storage2",
"injectionNominalCapacity": 2000.0,
Expand All @@ -164,6 +166,7 @@ def test_get_all_storages__nominal_case(
},
{
"id": "storage3",
"enabled": None,
"group": STStorageGroup.PSP_CLOSED,
"name": "Storage3",
"injectionNominalCapacity": 1500.0,
Expand Down Expand Up @@ -250,7 +253,7 @@ def test_get_st_storages__nominal_case(
"name": "Storage1",
"reservoirCapacity": 20000.0,
"withdrawalNominalCapacity": 1500.0,
"enabled": True, # present with default value even if the study is in v8.6
"enabled": None,
},
{
"efficiency": 0.78,
Expand All @@ -262,7 +265,7 @@ def test_get_st_storages__nominal_case(
"name": "Storage2",
"reservoirCapacity": 20000.0,
"withdrawalNominalCapacity": 1500.0,
"enabled": True,
"enabled": None,
},
{
"efficiency": 0.72,
Expand All @@ -274,7 +277,7 @@ def test_get_st_storages__nominal_case(
"name": "Storage3",
"reservoirCapacity": 21000.0,
"withdrawalNominalCapacity": 1500.0,
"enabled": True,
"enabled": None,
},
]
assert actual == expected
Expand Down Expand Up @@ -361,7 +364,7 @@ def test_get_st_storage__nominal_case(
"name": "Storage1",
"reservoirCapacity": 20000.0,
"withdrawalNominalCapacity": 1500.0,
"enabled": True,
"enabled": None,
}
assert actual == expected

Expand Down

0 comments on commit 95a5ac5

Please sign in to comment.