MCPcopy Index your code
hub / github.com/pydata/xarray / assert_consistent_text_and_html

Function assert_consistent_text_and_html

xarray/tests/test_formatting_html.py:29–37  ·  view source on GitHub ↗
(
    obj: XarrayTypes, section_headers: list[str]
)

Source from the content-addressed store, hash-verified

27
28
29def assert_consistent_text_and_html(
30 obj: XarrayTypes, section_headers: list[str]
31) -> None:
32 actual_html = xarray_html_only_repr(obj)
33 actual_text = repr(obj)
34 for section_header in section_headers:
35 assert actual_html.count(section_header) == actual_text.count(section_header), (
36 section_header
37 )
38
39
40assert_consistent_text_and_html_dataarray = partial(

Callers

nothing calls this directly

Calls 2

xarray_html_only_reprFunction · 0.85
countMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…