summaryrefslogtreecommitdiff
path: root/bs4/tests
AgeCommit message (Collapse)Author
2023-03-21Reimplemented the pretty-print algorithm to remove recursive function calls.Leonard Richardson
2023-03-20Removed an html5lib fuzz test case that is marked as fixed in oss-fuzz and ↵Leonard Richardson
was probably not ever an issue.
2023-03-20Linked another html5lib crash to the fuzz tests.Leonard Richardson
2023-03-20Added fuzz tests.Leonard Richardson
2023-03-20Added a test harness for clusterfuzz test cases.Leonard Richardson
2023-02-15When the html.parser parser decides it can't parse a document, BeautifulLeonard Richardson
Soup now consistently propagates this fact by raising a ParserRejectedMarkup error. [bug=2007343]
2023-02-10Add compile methodfacelessuser
2023-02-10Remove unnecessary test and don't pass namespace on precompiled selectfacelessuser
2023-02-07Removed Soup Sieve fallback method, added documentation.Leonard Richardson
2023-02-04Added a __getattr__ fallback.Leonard Richardson
2023-02-03Added tests of CSS.escape.Leonard Richardson
2023-02-03Move the Soup Sieve proxy and its tests into separate files.Leonard Richardson
2023-02-03Consistently use the name 'tag' instead of 'element,' since CSS selectors ↵Leonard Richardson
only operate on tags. Verify that select() and filter() return ResultSets.
2023-02-02Test implementation.Leonard Richardson
2023-01-31Fixed missing import that caused test failures when Soup Sieve is installed.Leonard Richardson
2023-01-31Consistently use pytest.mark.skipif to skip tests when the corresponding ↵Leonard Richardson
libraries are not installed.
2023-01-29Reworded the 'multi-valued attributes' portion of the documentation to make ↵Leonard Richardson
it more clear. [bug=1970767]
2023-01-27Parametrize the 'string is deprecated' warning test so we can test all of ↵Leonard Richardson
the relevant methods.
2023-01-27Check the associated filename for more warnings.Leonard Richardson
2023-01-27Change the tests that check warnings to also (indirectly) verify that the ↵Leonard Richardson
stacklevel associated with the warning is more or less correct.
2023-01-27Got rid of some more warnings by removing code that's not relevant anymore, ↵Leonard Richardson
now that the minimum supported Python version is 3.6.
2023-01-25Tag.interesting_string_types is now propagated when a tag isLeonard Richardson
copied. [bug=1990400]
2023-01-25Made the ISO-8859 test robust in a less hacky way.Leonard Richardson
2023-01-25Made the ISO-8859-1 smoke test more robust.Leonard Richardson
2023-01-25The HTMLFormatter and XMLFormatter constructors no longer return aLeonard Richardson
value. [bug=1992693]
2023-01-25Passing a Tag's .contents into PageElement.extend() now works theLeonard Richardson
same way as passing the Tag itself.
2022-05-15Fixed a test failure when cchardet is not installed butLeonard Richardson
charset_normalizer is. [bug=1973072]
2022-04-10Fixed another crash when overriding multi_valued_attributes and using theLeonard Richardson
html5lib parser. [bug=1948488]
2022-04-07Omit untrusted input when issuing warnings.Leonard Richardson
2021-12-21It's now possible to customize the way output is indented byLeonard Richardson
providing a value for the 'indent' argument to the Formatter constructor. The 'indent' argument works very similarly to the argument of the same name in the Python standard library's json.dump() method. [bug=1955497]
2021-12-17Fix a crash when pickling a BeautifulSoup object that has noLeonard Richardson
tree builder. [bug=1934003]
2021-11-29Do a better job of keeping track of namespaces as an XML document isLeonard Richardson
parsed, so that CSS selectors that use namespaces will do the right thing more often. [bug=1946243]
2021-10-24Added test of warn_if_markup_looks_like_xml.Leonard Richardson
2021-10-24Issue a warning when an HTML parser is used to parse a document thatLeonard Richardson
looks like XML but not XHTML. [bug=1939121]
2021-10-24Used a warning to formally deprecate the 'text' argument in favor of 'string'.Leonard Richardson
2021-10-23Changing find* tests to use string instead of text, except for one test that ↵Leonard Richardson
specifically checks that text is an alias for string.
2021-10-23Added a workaround for an lxml bug ↵Leonard Richardson
(https://bugs.launchpad.net/lxml/+bug/1948551) that caused problems when parsing a Unicode string beginning with BYTE ORDER MARK. [bug=1947768]
2021-10-23Fixed a crash when overriding multi_valued_attributes and using theLeonard Richardson
html5lib parser. [bug=1948488]
2021-10-11Added special string classes, RubyParenthesisString and RubyTextString,Leonard Richardson
to make it possible to treat ruby text specially in get_text() calls. [bug=1941980]
2021-10-11More test refactoring.Leonard Richardson
2021-10-11Broke up some monolithic unit test files.Leonard Richardson
2021-10-11Moved the test classes to tests/__init__.py.Leonard Richardson
2021-10-09Moved testing.py into the same package as the tests.Leonard Richardson
2021-09-12Ported unit tests to use pytest.Leonard Richardson
2021-09-07Goodbye, Python 2. [bug=1942919]Leonard Richardson
2021-06-01The 'replace_with()' method now takes a variable number of arguments,Leonard Richardson
and can be used to replace a single element with a sequence of elements. Patch by Bill Chandos.
2021-05-31The html.parser tree builder can now handles named entitiesLeonard Richardson
found in the HTML5 spec in much the same way that the html5lib tree builder does. Note that the lxml tree builder still handles named entities differently. [bug=1924908]
2021-04-08Brought in fuzz tests from the oss-project into Beautiful Soup's unit test ↵Leonard Richardson
suite.
2021-02-14NavigableString and its subclasses now implement the get_text()Leonard Richardson
method, as well as the properties .strings and .stripped_strings. These methods will either return the string itself, or nothing, so the only reason to use this is when iterating over a list of mixed Tag and NavigableString objects. [bug=1904309]
2021-02-14The 'html5' formatter now treats attributes whose values are theLeonard Richardson
empty string as HTML boolean attributes. Previously (and in other formatters), an attribute value must be set as None to be treated as a boolean attribute. In a future release, I plan to also give this behavior to the 'html' formatter. Patch by Isaac Muse. [bug=1915424]