From 74ca9989c3dc8c745b9b001b790587103c3e5a0f Mon Sep 17 00:00:00 2001 From: Werner Van Geit Date: Fri, 22 Mar 2024 10:48:55 +0100 Subject: [PATCH] Fix issues in arbor tests, wrt to sorted dir content etc --- bluepyopt/tests/test_ephys/test_create_acc.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/bluepyopt/tests/test_ephys/test_create_acc.py b/bluepyopt/tests/test_ephys/test_create_acc.py index a2b51ef4..baae6def 100644 --- a/bluepyopt/tests/test_ephys/test_create_acc.py +++ b/bluepyopt/tests/test_ephys/test_create_acc.py @@ -640,7 +640,7 @@ def test_cell_model_create_acc_replace_axon_without_instantiate(): def check_acc_dir(test_dir, ref_dir): - assert os.listdir(ref_dir) == os.listdir(test_dir) + assert sorted(os.listdir(ref_dir)) == sorted(os.listdir(test_dir)) ref_dir_ver_suffix = "_py" + "".join(sys.version.split(".")[:2]) ref_dir_ver = ref_dir.parent / (ref_dir.name + ref_dir_ver_suffix) @@ -699,8 +699,7 @@ def test_write_acc_simple(): ) check_acc_dir(test_dir, ref_dir) - except Exception as e: # fail with an older Arbor version - assert isinstance(e, NotImplementedError) + except NotImplementedError as e: # fail with an older Arbor version assert ( len(e.args) == 1 and e.args[0]