mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-26 21:39:43 +02:00
chore: linting
This commit is contained in:
parent
0a012dbc79
commit
ce952d2ad1
127 changed files with 821 additions and 517 deletions
|
|
@ -50,18 +50,18 @@ class TestParseBeforeDate:
|
|||
|
||||
|
||||
def _notification(**overrides) -> Notification:
|
||||
defaults = dict(
|
||||
id=1,
|
||||
user_id=uuid.uuid4(),
|
||||
search_space_id=3,
|
||||
type="document_processing",
|
||||
title="Title",
|
||||
message="Message",
|
||||
read=False,
|
||||
notification_metadata={"k": "v"},
|
||||
created_at=datetime(2024, 1, 1, tzinfo=UTC),
|
||||
updated_at=datetime(2024, 1, 2, tzinfo=UTC),
|
||||
)
|
||||
defaults = {
|
||||
"id": 1,
|
||||
"user_id": uuid.uuid4(),
|
||||
"search_space_id": 3,
|
||||
"type": "document_processing",
|
||||
"title": "Title",
|
||||
"message": "Message",
|
||||
"read": False,
|
||||
"notification_metadata": {"k": "v"},
|
||||
"created_at": datetime(2024, 1, 1, tzinfo=UTC),
|
||||
"updated_at": datetime(2024, 1, 2, tzinfo=UTC),
|
||||
}
|
||||
defaults.update(overrides)
|
||||
return Notification(**defaults)
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,9 @@ def test_operation_id_encodes_search_space():
|
|||
|
||||
def test_summary_title_and_message():
|
||||
"""The summary states the document and the used/limit page counts."""
|
||||
title, message = msg.summary("short.pdf", pages_used=95, pages_limit=100, pages_to_add=10)
|
||||
title, message = msg.summary(
|
||||
"short.pdf", pages_used=95, pages_limit=100, pages_to_add=10
|
||||
)
|
||||
assert title == "Page limit exceeded: short.pdf"
|
||||
assert message == (
|
||||
"This document has ~10 page(s) but you've used 95/100 pages. "
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue