MCPcopy Index your code
hub / github.com/numpy/numpy / test_basic

Method test_basic

numpy/lib/tests/test_twodim_base.py:43–57  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

41
42class TestEye:
43 def test_basic(self):
44 assert_equal(eye(4),
45 array([[1, 0, 0, 0],
46 [0, 1, 0, 0],
47 [0, 0, 1, 0],
48 [0, 0, 0, 1]]))
49
50 assert_equal(eye(4, dtype='f'),
51 array([[1, 0, 0, 0],
52 [0, 1, 0, 0],
53 [0, 0, 1, 0],
54 [0, 0, 0, 1]], 'f'))
55
56 assert_equal(eye(3) == 1,
57 eye(3, dtype=bool))
58
59 def test_uint64(self):
60 # Regression test for gh-9982

Callers

nothing calls this directly

Calls 3

assert_equalFunction · 0.90
eyeFunction · 0.90
arrayFunction · 0.90

Tested by

no test coverage detected