Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/test_rig_bluesky/plans.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
from bluesky.plans import count
from bluesky.utils import MsgGenerator
from dodal.common import inject
from dodal.common.beamlines.beamline_utils import get_path_provider
from dodal.devices.motors import XYZStage
from dodal.plan_stubs.data_session import attach_data_session_metadata_decorator
from dodal.plans import spec_scan
Expand All @@ -17,7 +16,7 @@
sample_stage = inject("sample_stage")


@attach_data_session_metadata_decorator(get_path_provider())
@attach_data_session_metadata_decorator()
def snapshot(
imaging_detector: AravisDetector = imaging_detector,
spectroscopy_detector: AravisDetector = spectroscopy_detector,
Expand Down
10 changes: 10 additions & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
from pathlib import Path

import pytest
from bluesky import RunEngine
from dodal.common.beamlines.beamline_utils import set_path_provider
from ophyd_async.core import StaticPathProvider, UUIDFilenameProvider


@pytest.fixture(scope="function")
Expand All @@ -8,3 +12,9 @@ def RE():
yield RE
if RE.state not in ("idle", "panicked"):
RE.halt()


@pytest.fixture(scope="session", autouse=True)
def path_provider() -> None:
provider = StaticPathProvider(UUIDFilenameProvider(), Path("/tmp"))
set_path_provider(provider)