Minimal test of DOMEventStream.parse()
(self)
| 26 | |
| 27 | @unittest.expectedFailure # TODO: RUSTPYTHON; FileNotFoundError: [Errno 2] No such file or directory (os error 2): 'xmltestdata/test.xml' -> 'None' |
| 28 | def test_parse(self): |
| 29 | """Minimal test of DOMEventStream.parse()""" |
| 30 | |
| 31 | # This just tests that parsing from a stream works. Actual parser |
| 32 | # semantics are tested using parseString with a more focused XML |
| 33 | # fragment. |
| 34 | |
| 35 | # Test with a filename: |
| 36 | handler = pulldom.parse(tstfile) |
| 37 | self.addCleanup(handler.stream.close) |
| 38 | list(handler) |
| 39 | |
| 40 | # Test with a file object: |
| 41 | with open(tstfile, "rb") as fin: |
| 42 | list(pulldom.parse(fin)) |
| 43 | |
| 44 | @unittest.expectedFailure # TODO: RUSTPYTHON; implement DOM semantic |
| 45 | def test_parse_semantics(self): |
nothing calls this directly
no test coverage detected