Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions lib/matplotlib/tests/test_cbook.py
Original file line number Diff line number Diff line change
Expand Up @@ -943,9 +943,8 @@ def test_auto_format_str(fmt, value, result):


def test_unpack_to_numpy_from_torch():
"""Test that torch tensors are converted to numpy arrays.
We don't want to create a dependency on torch in the test suite, so we mock it.
"""
# Test that torch tensors are converted to NumPy arrays.
# We don't want to create a dependency on torch in the test suite, so we mock it.
class Tensor:
def __init__(self, data):
self.data = data
Expand All @@ -963,9 +962,8 @@ def __array__(self):


def test_unpack_to_numpy_from_jax():
"""Test that jax arrays are converted to numpy arrays.
We don't want to create a dependency on jax in the test suite, so we mock it.
"""
# Test that jax arrays are converted to NumPy arrays.
# We don't want to create a dependency on jax in the test suite, so we mock it.
class Array:
def __init__(self, data):
self.data = data
Expand Down