diff --git a/src/spikeinterface/extractors/tests/test_nwbextractors_streaming.py b/src/spikeinterface/extractors/tests/test_nwbextractors_streaming.py index 045e7f8211..161040cbaf 100644 --- a/src/spikeinterface/extractors/tests/test_nwbextractors_streaming.py +++ b/src/spikeinterface/extractors/tests/test_nwbextractors_streaming.py @@ -224,8 +224,14 @@ def test_sorting_s3_nwb_zarr(tmp_path): # just take 3 random units to test rng = np.random.default_rng(seed=2205) three_unit_ids = rng.choice(sorting.unit_ids, size=3) - sorting_sub = sorting.select_units(unit_ids=three_unit_ids) - sorting_loaded_sub = sorting_loaded.select_units(unit_ids=three_unit_ids) + + first_spike_sample_index = 21864115 + sorting_sub = sorting.select_units(unit_ids=three_unit_ids).frame_slice( + start_frame=first_spike_sample_index, end_frame=first_spike_sample_index + 10_000 + ) + sorting_loaded_sub = sorting_loaded.select_units(unit_ids=three_unit_ids).frame_slice( + start_frame=first_spike_sample_index, end_frame=first_spike_sample_index + 10_000 + ) check_sortings_equal(sorting_sub, sorting_loaded_sub)