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

Method test_append_single

numpy/lib/tests/test_recfunctions.py:588–595  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

586 return w, x, y, z
587
588 def test_append_single(self):
589 # Test simple case
590 x = self._create_arrays()[1]
591 test = append_fields(x, 'A', data=[10, 20, 30])
592 control = ma.array([(1, 10), (2, 20), (-1, 30)],
593 mask=[(0, 0), (0, 0), (1, 0)],
594 dtype=[('f0', int), ('A', int)],)
595 assert_equal(test, control)
596
597 def test_append_double(self):
598 # Test simple case

Callers

nothing calls this directly

Calls 3

_create_arraysMethod · 0.95
append_fieldsFunction · 0.90
assert_equalFunction · 0.90

Tested by

no test coverage detected