MCPcopy Create free account
hub / github.com/pytest-dev/pytest / test_repr_nd_array

Method test_repr_nd_array

testing/python/approx.py:316–320  ·  view source on GitHub ↗

Make sure that arrays of all different dimensions are repr'd correctly.

(self, value, expected_repr_string)

Source from the content-addressed store, hash-verified

314 ],
315 )
316 def test_repr_nd_array(self, value, expected_repr_string):
317 """Make sure that arrays of all different dimensions are repr'd correctly."""
318 np = pytest.importorskip("numpy")
319 np_array = np.array(value)
320 assert repr(approx(np_array)) == expected_repr_string
321
322 def test_bool(self):
323 with pytest.raises(AssertionError) as err:

Callers

nothing calls this directly

Calls 1

approxFunction · 0.90

Tested by

no test coverage detected