File remove-spurious-xml-whitespace-test.patch of Package python-Twisted.26706
From 6b4bbf9040abd8e5c8feae026c4a6483c7f72506 Mon Sep 17 00:00:00 2001
From: Glyph <glyph@twistedmatrix.com>
Date: Sun, 27 Mar 2022 18:03:49 -0700
Subject: [PATCH] remove spurious test for illegal whitespace in xmlns
---
src/twisted/words/test/test_domish.py | 10 ----------
2 files changed, 10 deletions(-)
create mode 100644 src/twisted/newsfragments/10318.misc
Index: Twisted-19.10.0/src/twisted/words/test/test_domish.py
===================================================================
--- Twisted-19.10.0.orig/src/twisted/words/test/test_domish.py
+++ Twisted-19.10.0/src/twisted/words/test/test_domish.py
@@ -338,18 +338,6 @@ class DomishStreamTestsMixin:
self.assertEqual(self.elements[0].child2.uri, '')
- def test_namespaceWithWhitespace(self):
- """
- Whitespace in an xmlns value is preserved in the resulting node's C{uri}
- attribute.
- """
- xml = b"<root xmlns:foo=' bar baz '><foo:bar foo:baz='quux'/></root>"
- self.stream.parse(xml)
- self.assertEqual(self.elements[0].uri, " bar baz ")
- self.assertEqual(
- self.elements[0].attributes, {(" bar baz ", "baz"): "quux"})
-
-
def test_attributesWithNamespaces(self):
"""
Attributes with namespace are parsed correctly (#9730 regression test).