diff options
| author | Ezio Melotti <ezio.melotti@gmail.com> | 2012-06-23 15:27:51 +0200 |
|---|---|---|
| committer | Ezio Melotti <ezio.melotti@gmail.com> | 2012-06-23 15:27:51 +0200 |
| commit | 3861d8b27127a261391ee49ff8634a4ef3ba1dd3 (patch) | |
| tree | c76b34f4269c742f50be485890703200262def43 /Lib/test/test_htmlparser.py | |
| parent | a4db02c7a38c5669b5678f1e972d8b9c6d3a2238 (diff) | |
| download | cpython-git-3861d8b27127a261391ee49ff8634a4ef3ba1dd3.tar.gz | |
#15114: the strict mode of HTMLParser and the HTMLParseError exception are deprecated now that the parser is able to parse invalid markup.
Diffstat (limited to 'Lib/test/test_htmlparser.py')
| -rw-r--r-- | Lib/test/test_htmlparser.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Lib/test/test_htmlparser.py b/Lib/test/test_htmlparser.py index c4f80cca30..64a4f5dfb4 100644 --- a/Lib/test/test_htmlparser.py +++ b/Lib/test/test_htmlparser.py @@ -102,7 +102,8 @@ class TestCaseBase(unittest.TestCase): class HTMLParserStrictTestCase(TestCaseBase): def get_collector(self): - return EventCollector(strict=True) + with support.check_warnings(("", DeprecationWarning), quite=False): + return EventCollector(strict=True) def test_processing_instruction_only(self): self._run_check("<?processing instruction>", [ @@ -594,7 +595,8 @@ class HTMLParserTolerantTestCase(HTMLParserStrictTestCase): class AttributesStrictTestCase(TestCaseBase): def get_collector(self): - return EventCollector(strict=True) + with support.check_warnings(("", DeprecationWarning), quite=False): + return EventCollector(strict=True) def test_attr_syntax(self): output = [ |
