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

Method test_addfield

numpy/ma/tests/test_mrecords.py:477–483  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

475 assert_equal(mrectxt.C, [1, 2, 3.e+5, -1e-10])
476
477 def test_addfield(self):
478 # Tests addfield
479 (mrec, nrec, ddtype) = self.data
480 (d, m) = ([100, 200, 300], [1, 0, 0])
481 mrec = addfield(mrec, ma.array(d, mask=m))
482 assert_equal(mrec.f3, d)
483 assert_equal(mrec.f3._mask, m)
484
485
486def test_record_array_with_object_field():

Callers

nothing calls this directly

Calls 2

addfieldFunction · 0.90
assert_equalFunction · 0.90

Tested by

no test coverage detected