From cb26e66a574cf77bdc8276beddc5db990f406a3b Mon Sep 17 00:00:00 2001 From: mavaylon1 Date: Thu, 14 Mar 2024 13:49:58 -0700 Subject: [PATCH] test --- src/hdmf/term_set.py | 2 +- tests/unit/common/test_table.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/hdmf/term_set.py b/src/hdmf/term_set.py index abbaf0b3c..39e3cd40d 100644 --- a/src/hdmf/term_set.py +++ b/src/hdmf/term_set.py @@ -317,7 +317,7 @@ def extend(self, arg): if isinstance(arg, np.ndarray): values = arg[self.__field] else: - values = [arg] + values = arg bad_data = [] for item in values: if not self.termset.validate(term=item): diff --git a/tests/unit/common/test_table.py b/tests/unit/common/test_table.py index 49b39b591..5c09caa4d 100644 --- a/tests/unit/common/test_table.py +++ b/tests/unit/common/test_table.py @@ -245,7 +245,7 @@ def test_add_ref_compound_data_extend(self): np.testing.assert_array_equal(compound_vector_data.data, np.vstack((c_data, c_data2))) - + @unittest.skipIf(not LINKML_INSTALLED, "optional LinkML module is not installed") def test_add_ref_wrapped_compound_data_append(self): c_data = np.array([('Homo sapiens', 24)], dtype=[('species', 'U50'), ('age', 'i4')]) c_data2 = np.array([('Mus musculus', 24)], dtype=[('species', 'U50'), ('age', 'i4')]) @@ -259,6 +259,7 @@ def test_add_ref_wrapped_compound_data_append(self): np.testing.assert_array_equal(compound_vector_data.data.data, np.append(c_data, c_data2)) + @unittest.skipIf(not LINKML_INSTALLED, "optional LinkML module is not installed") def test_add_ref_wrapped_compound_data_extend(self): c_data = np.array([('Homo sapiens', 24)], dtype=[('species', 'U50'), ('age', 'i4')]) c_data2 = np.array([('Mus musculus', 24)], dtype=[('species', 'U50'), ('age', 'i4')])