Exemplo n.º 1
0
 def test_has_nested_dtype(self):
     "Test has_nested_dtype"
     ndtype = np.dtype(float)
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([('A', '|S3'), ('B', float)])
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([('A', int), ('B', [('BA', float), ('BB', '|S1')])])
     assert_equal(has_nested_fields(ndtype), True)
Exemplo n.º 2
0
 def test_has_nested_dtype(self):
     "Test has_nested_dtype"
     ndtype = np.dtype(np.float)
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([('A', '|S3'), ('B', float)])
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([('A', int), ('B', [('BA', float), ('BB', '|S1')])])
     assert_equal(has_nested_fields(ndtype), True)
Exemplo n.º 3
0
 def test_has_nested_dtype(self):
     "Test has_nested_dtype"
     ndtype = np.dtype(float)
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([("A", "|S3"), ("B", float)])
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([("A", int), ("B", [("BA", float), ("BB", "|S1")])])
     assert_equal(has_nested_fields(ndtype), True)
Exemplo n.º 4
0
 def test_has_nested_dtype(self):
     "Test has_nested_dtype"
     ndtype = np.dtype(np.float)
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([("A", "|S3"), ("B", float)])
     assert_equal(has_nested_fields(ndtype), False)
     ndtype = np.dtype([("A", int), ("B", [("BA", float), ("BB", "|S1")])])
     assert_equal(has_nested_fields(ndtype), True)