MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / test_clipping_full

Function test_clipping_full

lib/matplotlib/tests/test_simplification.py:508–521  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

506
507
508def test_clipping_full():
509 p = Path([[1e30, 1e30]] * 5)
510 simplified = list(p.iter_segments(clip=[0, 0, 100, 100]))
511 assert simplified == []
512
513 p = Path([[50, 40], [75, 65]], [1, 2])
514 simplified = list(p.iter_segments(clip=[0, 0, 100, 100]))
515 assert ([(list(x), y) for x, y in simplified] ==
516 [([50, 40], 1), ([75, 65], 2)])
517
518 p = Path([[50, 40]], [1])
519 simplified = list(p.iter_segments(clip=[0, 0, 100, 100]))
520 assert ([(list(x), y) for x, y in simplified] ==
521 [([50, 40], 1)])
522
523
524def test_simplify_closepoly():

Callers

nothing calls this directly

Calls 2

iter_segmentsMethod · 0.95
PathClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…