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

Function test_patch_has_dashed_edge

lib/matplotlib/tests/test_patches.py:1135–1152  ·  view source on GitHub ↗

Test _has_dashed_edge method for patches.

()

Source from the content-addressed store, hash-verified

1133
1134
1135def test_patch_has_dashed_edge():
1136 """Test _has_dashed_edge method for patches."""
1137 patch = Rectangle((0, 0), 1, 1)
1138 patch.set_linestyle('solid')
1139 assert not patch._has_dashed_edge()
1140
1141 patch.set_linestyle('--')
1142 assert patch._has_dashed_edge()
1143
1144 patch.set_linestyle(':')
1145 assert patch._has_dashed_edge()
1146
1147 patch.set_linestyle('-.')
1148 assert patch._has_dashed_edge()
1149
1150 # Test custom linestyle
1151 patch.set_linestyle((0, (2, 2, 10, 2)))
1152 assert patch._has_dashed_edge()
1153
1154
1155def test_patch_edgegapcolor_update_from():

Callers

nothing calls this directly

Calls 3

RectangleClass · 0.90
_has_dashed_edgeMethod · 0.80
set_linestyleMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…