From da7c22f710a93ee75fa8cbfcd2e3d58dc965294a Mon Sep 17 00:00:00 2001 From: Henrik Levkowetz Date: Wed, 26 Aug 2020 16:04:50 +0000 Subject: [PATCH] Added html.escape() in a test case in order to correctly handle affiliation names with ampersands. - Legacy-Id: 18420 --- ietf/api/tests.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ietf/api/tests.py b/ietf/api/tests.py index 89f9a67ee..bf7a5801e 100644 --- a/ietf/api/tests.py +++ b/ietf/api/tests.py @@ -3,6 +3,7 @@ import json +import html import os import shutil import sys @@ -229,7 +230,7 @@ class CustomApiTests(TestCase): text = file.read() for p in people: self.assertIn(p['name'], text) - self.assertIn(p['affiliation'], text) + self.assertIn(html.escape(p['affiliation']), text) def test_person_export(self): person = PersonFactory()