MCPcopy Create free account
hub / github.com/numpy/numpy / test_shape_argument

Method test_shape_argument

numpy/ma/tests/test_core.py:2378–2388  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2376 assert_equal(a.fill_value, 0.)
2377
2378 def test_shape_argument(self):
2379 # Test that shape can be provides as an argument
2380 # GH issue 6106
2381 a = empty(shape=(3, ))
2382 assert_equal(a.shape, (3, ))
2383
2384 a = ones(shape=(3, ), dtype=float)
2385 assert_equal(a.shape, (3, ))
2386
2387 a = zeros(shape=(3, ), dtype=complex)
2388 assert_equal(a.shape, (3, ))
2389
2390 def test_fillvalue_in_view(self):
2391 # Test the behavior of fill_value in view

Callers

nothing calls this directly

Calls 4

assert_equalFunction · 0.90
onesFunction · 0.90
emptyFunction · 0.50
zerosFunction · 0.50

Tested by

no test coverage detected