(self)
| 73 | self.assertEqual(len(document.childNodes), 1) |
| 74 | |
| 75 | def test_parse_with_systemId(self): |
| 76 | response = io.BytesIO(SMALL_SAMPLE) |
| 77 | |
| 78 | with mock.patch("urllib.request.urlopen") as mock_open: |
| 79 | mock_open.return_value = response |
| 80 | |
| 81 | imp = getDOMImplementation() |
| 82 | source = imp.createDOMInputSource() |
| 83 | builder = imp.createDOMBuilder(imp.MODE_SYNCHRONOUS, None) |
| 84 | source.systemId = "http://example.com/2000/svg" |
| 85 | document = builder.parse(source) |
| 86 | |
| 87 | self.assertIsInstance(document, minidom.Document) |
| 88 | self.assertEqual(len(document.childNodes), 1) |
nothing calls this directly
no test coverage detected