dandi.tests.fixtures¶
Functions
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Create nwbfiles sharing video files. |
|
Create nwbfiles linked with unique set of videos. |
|
|
|
|
|
|
|
Organized NWB directory with one file having one best practice violation, and another file having two best practice violations. |
|
|
|
|
|
With a subject |
|
With a subject, but no subject_id. |
|
With subject, subject_id, species, but including data orientation ambiguity. |
|
With subject, subject_id, species, but including data orientation ambiguity, and missing the |
|
|
|
|
|
|
|
Classes
|
|
|
|
|
- class dandi.tests.fixtures.DandiAPI(api_key: 'str', client: 'DandiAPIClient')[source]¶
- api_key: str¶
- property api_url: str¶
- client: DandiAPIClient¶
- property instance: DandiInstance¶
- property instance_id: str¶
- class dandi.tests.fixtures.SampleDandiset(api: 'DandiAPI', dspath: 'Path', dandiset: 'RemoteDandiset', dandiset_id: 'str', upload_kwargs: 'dict[str, Any]' = <factory>)[source]¶
-
- property client: DandiAPIClient¶
- dandiset: RemoteDandiset¶
- dandiset_id: str¶
- dspath: Path¶
- upload_kwargs: dict[str, Any]¶
- class dandi.tests.fixtures.SampleDandisetFactory(local_dandi_api: 'DandiAPI', tmp_path_factory: 'pytest.TempPathFactory')[source]¶
-
- mkdandiset(name: str, embargo: bool = False) SampleDandiset [source]¶
- tmp_path_factory: TempPathFactory¶
- dandi.tests.fixtures.bids_dandiset(new_dandiset: SampleDandiset, bids_examples: Path) SampleDandiset [source]¶
- dandi.tests.fixtures.bids_dandiset_invalid(new_dandiset: SampleDandiset, bids_error_examples: Path) SampleDandiset [source]¶
- dandi.tests.fixtures.bids_error_examples(tmp_path_factory: pytest.TempPathFactory) Iterator[Path] ¶
- dandi.tests.fixtures.bids_examples(tmp_path_factory: pytest.TempPathFactory) Iterator[Path] ¶
- dandi.tests.fixtures.bids_nwb_dandiset(new_dandiset: SampleDandiset, bids_examples: Path) SampleDandiset [source]¶
- dandi.tests.fixtures.bids_zarr_dandiset(new_dandiset: SampleDandiset, bids_examples: Path) SampleDandiset [source]¶
- dandi.tests.fixtures.get_filtered_gitrepo_fixture(url: str, whitelist: list[str], make_subdirs_dandisets: bool | None = False) Callable[[pytest.TempPathFactory], Iterator[Path]] [source]¶
- dandi.tests.fixtures.get_gitrepo_fixture(url: str, committish: str | None = None, scope: Scope = 'session', make_subdirs_dandisets: bool = False) Callable[[pytest.TempPathFactory], Path] [source]¶
- dandi.tests.fixtures.local_dandi_api(docker_compose_setup: dict[str, str]) Iterator[DandiAPI] [source]¶
- dandi.tests.fixtures.new_dandiset(request: FixtureRequest, sample_dandiset_factory: SampleDandisetFactory) SampleDandiset [source]¶
- dandi.tests.fixtures.nwb_dandiset(new_dandiset: SampleDandiset, simple2_nwb: Path) SampleDandiset [source]¶
- dandi.tests.fixtures.nwb_test_data(tmp_path_factory: TempPathFactory) Path ¶
- dandi.tests.fixtures.nwbfiles_video_common(video_files: list[tuple[Path, Path]]) Path [source]¶
Create nwbfiles sharing video files.
- dandi.tests.fixtures.nwbfiles_video_unique(video_files: list[tuple[Path, Path]]) Path [source]¶
Create nwbfiles linked with unique set of videos.
- dandi.tests.fixtures.organized_nwb_dir(simple2_nwb: Path, tmp_path_factory: TempPathFactory) Path [source]¶
- dandi.tests.fixtures.organized_nwb_dir2(simple1_nwb_metadata: dict[str, Any], simple2_nwb: Path, tmp_path_factory: pytest.TempPathFactory) Path [source]¶
- dandi.tests.fixtures.organized_nwb_dir3(simple4_nwb: Path, tmp_path_factory: TempPathFactory) Path [source]¶
- dandi.tests.fixtures.organized_nwb_dir4(simple4_nwb: Path, simple5_nwb: Path, tmp_path_factory: TempPathFactory) Path [source]¶
Organized NWB directory with one file having one best practice violation, and another file having two best practice violations.
- dandi.tests.fixtures.sample_dandiset_factory(local_dandi_api: DandiAPI, tmp_path_factory: TempPathFactory) SampleDandisetFactory [source]¶
- dandi.tests.fixtures.simple1_nwb(simple1_nwb_metadata: dict[str, Any], tmp_path_factory: pytest.TempPathFactory) Path [source]¶
- dandi.tests.fixtures.simple2_nwb(simple1_nwb_metadata: dict[str, Any], tmp_path_factory: pytest.TempPathFactory) Path [source]¶
With a subject
- dandi.tests.fixtures.simple3_nwb(simple1_nwb_metadata: dict[str, Any], tmp_path_factory: pytest.TempPathFactory) Path [source]¶
With a subject, but no subject_id.
- dandi.tests.fixtures.simple4_nwb(tmp_path_factory: TempPathFactory) Path [source]¶
With subject, subject_id, species, but including data orientation ambiguity.
- dandi.tests.fixtures.simple5_nwb(tmp_path_factory: TempPathFactory) Path [source]¶
With subject, subject_id, species, but including data orientation ambiguity, and missing the
pywnb.Timeseries
unit
attribute.Notes
- These are both best practice violations, as per the discussion upstream:
https://github.com/NeurodataWithoutBorders/nwbinspector/issues/345#issuecomment-1459232718
- dandi.tests.fixtures.text_dandiset(new_dandiset: SampleDandiset) SampleDandiset [source]¶
- dandi.tests.fixtures.tmp_home(monkeypatch: MonkeyPatch, tmp_path_factory: TempPathFactory) Path [source]¶
- dandi.tests.fixtures.zarr_dandiset(new_dandiset: SampleDandiset) SampleDandiset [source]¶