(self)
| 490 | assert_equal(test.mask, control.mask) |
| 491 | |
| 492 | def test_flatten(self): |
| 493 | # Test standard & flexible |
| 494 | (_, x, _, z) = self.data |
| 495 | test = merge_arrays((x, z), flatten=True) |
| 496 | control = np.array([(1, 'A', 1.), (2, 'B', 2.)], |
| 497 | dtype=[('f0', int), ('A', '|S3'), ('B', float)]) |
| 498 | assert_equal(test, control) |
| 499 | |
| 500 | test = merge_arrays((x, z), flatten=False) |
| 501 | control = np.array([(1, ('A', 1.)), (2, ('B', 2.))], |
| 502 | dtype=[('f0', int), |
| 503 | ('f1', [('A', '|S3'), ('B', float)])]) |
| 504 | assert_equal(test, control) |
| 505 | |
| 506 | def test_flatten_wflexible(self): |
| 507 | # Test flatten standard & nested |
nothing calls this directly
no test coverage detected