Skip to content

Commit ecdcadf

Browse files
committed
Delete the delete_me function
And add a temporary `test_loading` function to keep pytest from failing. Signed-off-by: Sahas Subramanian <[email protected]>
1 parent e1da85a commit ecdcadf

File tree

2 files changed

+5
-33
lines changed

2 files changed

+5
-33
lines changed
Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,4 @@
11
# License: MIT
22
# Copyright © 2025 Frequenz Energy-as-a-Service GmbH
33

4-
"""Python bindings for the Frequenz microgrid component graph rust library..
5-
6-
TODO(cookiecutter): Add a more descriptive module description.
7-
"""
8-
9-
10-
# TODO(cookiecutter): Remove this function
11-
def delete_me(*, blow_up: bool = False) -> bool:
12-
"""Do stuff for demonstration purposes.
13-
14-
Args:
15-
blow_up: If True, raise an exception.
16-
17-
Returns:
18-
True if no exception was raised.
19-
20-
Raises:
21-
RuntimeError: if blow_up is True.
22-
"""
23-
if blow_up:
24-
raise RuntimeError("This function should be removed!")
25-
return True
4+
"""Python bindings for the Frequenz microgrid component graph rust library."""

tests/test_microgrid_component_graph.py

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,10 @@
22
# Copyright © 2025 Frequenz Energy-as-a-Service GmbH
33

44
"""Tests for the frequenz.microgrid_component_graph package."""
5-
import pytest
65

7-
from frequenz.microgrid_component_graph import delete_me
6+
from frequenz import microgrid_component_graph
87

98

10-
def test_microgrid_component_graph_succeeds() -> None: # TODO(cookiecutter): Remove
11-
"""Test that the delete_me function succeeds."""
12-
assert delete_me() is True
13-
14-
15-
def test_microgrid_component_graph_fails() -> None: # TODO(cookiecutter): Remove
16-
"""Test that the delete_me function fails."""
17-
with pytest.raises(RuntimeError, match="This function should be removed!"):
18-
delete_me(blow_up=True)
9+
def test_loading() -> None:
10+
"""Test that the microgrid_component_graph module loads correctly."""
11+
assert microgrid_component_graph is not None

0 commit comments

Comments
 (0)