MCPcopy
hub / github.com/numpy/numpy / test_subclass

Method test_subclass

numpy/_core/tests/test_function_base.py:135–143  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

133 assert_equal(logspace(a, b), logspace(1.0, 5.0))
134
135 def test_subclass(self):
136 a = array(1).view(PhysicalQuantity2)
137 b = array(7).view(PhysicalQuantity2)
138 ls = logspace(a, b)
139 assert type(ls) is PhysicalQuantity2
140 assert_equal(ls, logspace(1.0, 7.0))
141 ls = logspace(a, b, 1)
142 assert type(ls) is PhysicalQuantity2
143 assert_equal(ls, logspace(1.0, 7.0, 1))
144
145
146class TestGeomspace:

Callers

nothing calls this directly

Calls 4

arrayFunction · 0.90
logspaceFunction · 0.90
assert_equalFunction · 0.90
viewMethod · 0.45

Tested by

no test coverage detected