Skip to content

Commit de2bf8e

Browse files
committed
fix tests
1 parent db4ad4f commit de2bf8e

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

ibllib/oneibl/data_handlers.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,8 @@ def uploadData(self, outputs, version, clobber=False, **kwargs):
140140
versions = super().uploadData(outputs, version)
141141
data_repo = get_local_data_repository(self.one.alyx)
142142
# If clobber = False, do not re-upload the outputs that have already been processed
143+
if not isinstance(outputs, list):
144+
outputs = [outputs]
143145
to_upload = list(filter(None if clobber else lambda x: x not in self.processed, outputs))
144146
records = register_dataset(to_upload, one=self.one, versions=versions, repository=data_repo, **kwargs) or []
145147
if kwargs.get('dry', False):

ibllib/tests/test_oneibl.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,8 @@ def test_task_names_extractors(self):
244244
self.assertEqual(out, to[1])
245245
# also makes sure that all task types have a defined procedure
246246
task_types = ibllib.io.extractors.base._get_task_types_json_config()
247+
for key in ['THIS FILE', 'SEE', '********', '************']:
248+
task_types.pop(key)
247249
for task_type in set([task_types[tt] for tt in task_types]):
248250
assert registration._alyx_procedure_from_task_type(task_type) is not None, task_type + ' has no associate procedure'
249251

0 commit comments

Comments
 (0)