Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add tests for issue #355 #426

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/icalendar/tests/events/issue_355_url_escaping.ics
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
BEGIN:VEVENT
DTSTAMP:20220822T164528Z
UID:[email protected]
DTSTART;TZID=Europe/Berlin:20220822T120000
DTEND;TZID=Europe/Berlin:20220822T120000
SUMMARY:test
DESCRIPTION:https://www.facebook.com/events/756119502186737/?acontext=%7B%22source%22%3A5%2C%22action_history%22%3A[%7B%22surface%22%3A%22page%22%2C%22mechanism%22%3A%22main_list%22%2C%22extra_data%22%3A%22%5C%22[]%5C%22%22%7D]%2C%22has_source%22%3Atrue%7D
END:VEVENT
11 changes: 11 additions & 0 deletions src/icalendar/tests/test_issue_355_url_escaping.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
"""Tests for Issue 355.

see https://github.com/collective/icalendar/issues/355
"""

def test_facebook_link_is_correctly_parsed(events):
"""The facebook link must not be damaged.

see https://github.com/collective/icalendar/pull/356#issuecomment-1222626128
"""
events.issue_355_url_escaping["DESCRIPTION"] == "https://www.facebook.com/events/756119502186737/?acontext=%7B%22source%22%3A5%2C%22action_history%22%3A[%7B%22surface%22%3A%22page%22%2C%22mechanism%22%3A%22main_list%22%2C%22extra_data%22%3A%22%5C%22[]%5C%22%22%7D]%2C%22has_source%22%3Atrue%7D"
niccokunzmann marked this conversation as resolved.
Show resolved Hide resolved