diff options
Diffstat (limited to 'bs4/tests/test_soup.py')
-rw-r--r-- | bs4/tests/test_soup.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/bs4/tests/test_soup.py b/bs4/tests/test_soup.py index 10a7e55..d826b25 100644 --- a/bs4/tests/test_soup.py +++ b/bs4/tests/test_soup.py @@ -2,7 +2,10 @@ """Tests of Beautiful Soup as a whole.""" import unittest -from bs4 import BeautifulSoup +from bs4 import ( + BeautifulSoup, + BeautifulStoneSoup, +) from bs4.element import ( SoupStrainer, NamespacedAttribute, @@ -44,6 +47,12 @@ class TestDeprecatedConstructorArguments(SoupTest): self.assertRaises( TypeError, self.soup, "<a>", no_such_argument=True) + def test_beautifulstonesoup(self): + with warnings.catch_warnings(record=True) as w: + soup = BeautifulStoneSoup("<markup>") + self.assertTrue(isinstance(soup, BeautifulSoup)) + self.assertTrue("BeautifulStoneSoup class is deprecated") + class TestSelectiveParsing(SoupTest): def test_parse_with_soupstrainer(self): |