fix(msteams): normalize nbsp in inbound text

This commit is contained in:
T3chC0wb0y
2026-04-26 00:56:06 +08:00
committed by Xubin Ren
parent 722d935d37
commit fd3d7ea752
2 changed files with 20 additions and 1 deletions
+11
View File
@@ -261,6 +261,17 @@ def test_sanitize_inbound_text_keeps_normal_inline_message(make_channel):
assert ch._sanitize_inbound_text(activity) == "normal inline message"
def test_sanitize_inbound_text_normalizes_nbsp_entities(make_channel):
ch = make_channel()
activity = {
"text": "Hello from Teams",
"channelData": {},
}
assert ch._sanitize_inbound_text(activity) == "Hello from Teams"
def test_sanitize_inbound_text_normalizes_reply_wrapper_without_reply_metadata(make_channel):
ch = make_channel()