ibllib.tests.test_mesoscope

Tests for ibllib.pipes.mesoscope_tasks

Classes

TestImagingMeta

Test raw imaging metadata versioning.

TestMesoscopeFOV

Test for MesoscopeFOV task and associated functions.

TestMesoscopePreprocess

Test for MesoscopePreprocess task.

TestRegisterFOV

Test for MesoscopeFOV.register_fov method.

class TestMesoscopePreprocess(methodName='runTest')[source]

Bases: TestCase

Test for MesoscopePreprocess task.

setUp() None[source]

Hook method for setting up the test fixture before exercising it.

test_meta()[source]

Test arguments that are overwritten by meta file and set in task.kwargs, and that explicitly passed kwargs overwrite default and meta args

test_get_default_tau()[source]

Test for MesoscopePreprocess.get_default_tau method.

tearDown() None[source]

Hook method for deconstructing the test fixture after testing it.

class TestMesoscopeFOV(methodName='runTest')[source]

Bases: TestCase

Test for MesoscopeFOV task and associated functions.

test_get_provenance()[source]

Test for MesoscopeFOV.get_provenance method.

test_find_triangle()[source]

Test for find_triangle function.

test_surface_normal()[source]

Test for surface_normal function.

test_nearest_neighbour_1d()[source]

Test for _nearest_neighbour_1d function.

test_update_surgery_json()[source]

Test for MesoscopeFOV.update_surgery_json method.

Here we mock the Alyx object and simply check the method’s calls.

class TestRegisterFOV(methodName='runTest')[source]

Bases: TestCase

Test for MesoscopeFOV.register_fov method.

setUp() None[source]

Hook method for setting up the test fixture before exercising it.

test_register_fov()[source]

Test MesoscopeFOV.register_fov method.

Note this doesn’t actually hit Alyx. Also this doesn’t test stack creation.

tearDown() None[source]

The ONE function is cached and therefore the One object persists beyond this test. Here we return the mode back to the default after testing behaviour in offline mode.

class TestImagingMeta(methodName='runTest')[source]

Bases: TestCase

Test raw imaging metadata versioning.

test_patch_imaging_meta()[source]

Test for ibllib.io.extractors.mesoscope.patch_imaging_meta function.