1
0
mirror of https://codeberg.org/fediverse/fep.git synced 2026-08-05 19:55:46 +00:00

Automatically add discussionTo link (#490)

Reviewed-on: https://codeberg.org/fediverse/fep/pulls/490
Reviewed-by: silverpill <silverpill@noreply.codeberg.org>
Co-authored-by: Helge <helge.krueger@gmail.com>
Co-committed-by: Helge <helge.krueger@gmail.com>
This commit is contained in:
Helge
2025-03-07 10:11:22 +00:00
committed by helge
parent 40435aed84
commit cfcdb9272f
3 changed files with 55 additions and 14 deletions
+20 -1
View File
@@ -1,6 +1,6 @@
from datetime import date, timedelta
from .issue import parse_and_update_date_received
from .issue import parse_and_update_date_received, create_body
def test_parse_and_update_date_received():
@@ -22,3 +22,22 @@ def test_parse_and_update_date_received_outdated():
result = parse_and_update_date_received((today - timedelta(days=60)).isoformat())
assert result == today
def test_create_body():
result = create_body("fep-0000.md", date(2025, 2, 8))
assert (
result
== """
The [proposal](https://codeberg.org/fediverse/fep/src/branch/main/fep-0000.md) has been received. Thank you!
This issue tracks discussions and updates to the proposal during the `DRAFT` period.
Please post links to relevant discussions as comments to this issue.
`dateReceived`: 2025-02-08
If no further actions are taken, the proposal may be set by the facilitators to `WITHDRAWN` on 2026-02-08 (in 1 year).
"""
)