Skip to content

Commit 6ebfc0a

Browse files
committed
fix remaining unit tests
1 parent 6e1e262 commit 6ebfc0a

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

packages/jupyter-ai/jupyter_ai/tests/test_config_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ def configure_with_fields(cm: ConfigManager, completions: bool = False):
233233

234234
def test_snapshot_default_config(cm: ConfigManager, snapshot):
235235
config_from_cm: DescribeConfigResponse = cm.get_config()
236-
assert config_from_cm == snapshot(exclude=lambda prop, path: prop == "last_read")
236+
assert config_from_cm.model_dump() == snapshot(exclude=lambda prop, path: prop == "last_read")
237237

238238

239239
def test_init_with_existing_config(cm: ConfigManager, common_cm_kwargs):

packages/jupyter-ai/jupyter_ai/tests/test_context_providers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
@pytest.fixture
1212
def human_chat_message() -> HumanChatMessage:
1313
chat_client = ChatClient(
14-
id=0, username="test", initials="test", name="test", display_name="test"
14+
id="test-client-uuid", username="test", initials="test", name="test", display_name="test"
1515
)
1616
prompt = (
1717
"@file:test1.py @file @file:dir/test2.md test test\n"

packages/jupyter-ai/jupyter_ai/tests/test_handlers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ class TestException(Exception):
8888
@pytest.fixture
8989
def chat_client():
9090
return ChatClient(
91-
id=0, username="test", initials="test", name="test", display_name="test"
91+
id="test-client-uuid", username="test", initials="test", name="test", display_name="test"
9292
)
9393

9494

0 commit comments

Comments
 (0)