Skip to content

Commit 6177bc9

Browse files
Mike ProsserMike Prosser
authored andcommitted
cleanup
1 parent bdd6ce9 commit 6177bc9

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

src/nipanel/_panel_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ def close_panel(self, panel_id: str, reset: bool) -> None:
8080
self._invoke_with_retry(self._get_stub().ClosePanel, close_panel_request)
8181

8282
def enumerate_panels(self) -> dict[str, tuple[bool, list[str]]]:
83-
"""Enumerate all open panels.
83+
"""Enumerate all available panels.
8484
8585
Returns:
8686
A dictionary mapping panel IDs to a tuple containing a boolean indicating if the panel

tests/unit/test_panel_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ def test___open_panels___both_panels_open_and_in_memory(fake_panel_channel: grpc
2222
}
2323

2424

25-
def test___open_panels___close_panel_1_with_reset___panel_1_not_in_memory(
25+
def test___open_panels___close_panel_1_with_reset___enumerate_has_panel_2(
2626
fake_panel_channel: grpc.Channel,
2727
) -> None:
2828
client = create_panel_client(fake_panel_channel)
@@ -36,7 +36,7 @@ def test___open_panels___close_panel_1_with_reset___panel_1_not_in_memory(
3636
}
3737

3838

39-
def test___open_panels___close_panel_1_without_reset___both_panels_in_memory(
39+
def test___open_panels___close_panel_1_without_reset___enumerate_has_both_panels(
4040
fake_panel_channel: grpc.Channel,
4141
) -> None:
4242
client = create_panel_client(fake_panel_channel)

tests/unit/test_streamlit_panel.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def test___first_open_panel_fails___open_panel___gets_value(
111111
assert panel.get_value(value_id) == string_value
112112

113113

114-
def test___unopened_panel___set_value___client_has_value(
114+
def test___unopened_panel___set_value___sets_value(
115115
fake_panel_channel: grpc.Channel,
116116
) -> None:
117117
"""Test that set_value() succeeds before the user opens the panel."""
@@ -210,7 +210,6 @@ def test___open_panel___panel_is_open_and_in_memory(
210210
def test___with_panel___opens_and_closes_panel(
211211
fake_panel_channel: grpc.Channel,
212212
) -> None:
213-
"""Test that using the panel in a with statement opens and closes it."""
214213
panel = StreamlitPanel("my_panel", "path/to/script", grpc_channel=fake_panel_channel)
215214

216215
with panel:
@@ -224,7 +223,6 @@ def test___with_panel___opens_and_closes_panel(
224223
def test___with_panel___set_value___gets_same_value(
225224
fake_panel_channel: grpc.Channel,
226225
) -> None:
227-
"""Test that using the panel in a with statement allows setting and getting values."""
228226
with StreamlitPanel("my_panel", "path/to/script", grpc_channel=fake_panel_channel) as panel:
229227
value_id = "test_id"
230228
string_value = "test_value"

0 commit comments

Comments
 (0)