8000 Fix faulty test, fix wrong Affine2D call. · matplotlib/matplotlib@3f26a2f · GitHub
[go: up one dir, main page]

Skip to content

Commit 3f26a2f

Browse files
committed
Fix faulty test, fix wrong Affine2D call.
1 parent da5c90e commit 3f26a2f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/matplotlib/backend_bases.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ def draw_path_collection(self, gc, master_transform, paths, all_transforms,
221221
behavior of :meth:`draw_path_collection` can be made globally.
222222
"""
223223
path_ids = [
224-
(path, transforms.Affine2D(transform))
224+
(path, transforms.Affine2D(transform.get_matrix()))
225225
for path, transform in self._iter_collection_raw_paths(
226226
master_transform, paths, all_transforms)]
227227

lib/matplotlib/tests/test_backend_bases.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
def test_uses_per_path():
1515
id = transforms.Affine2D()
1616
paths = [path.Path.unit_regular_polygon(i) for i in range(3, 7)]
17-
tforms = [id.rotate(i) for i in range(1, 5)]
17+
tforms = [id.rotate(i).get_matrix().copy() for i in range(1, 5)]
1818
offsets = np.arange(20).reshape((10, 2))
1919
facecolors = ['red', 'green']
2020
edgecolors = ['red', 'green']

0 commit comments

Comments
 (0)
0