Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an option to connect to devices with mock=True #732

Open
d-perl opened this issue Nov 28, 2024 · 1 comment
Open

Add an option to connect to devices with mock=True #732

d-perl opened this issue Nov 28, 2024 · 1 comment
Labels
devices connection enhancement New feature or request
Milestone

Comments

@d-perl
Copy link
Contributor

d-perl commented Nov 28, 2024

When doing end-to-end testing, e.g. calling plans from my new GUI, I'd like to be able to run an instance of BlueAPI with mock devices to run plans against.

I've looked through the code a bit and can't find anything like it, but if it already exists then this issue is to add it to the docs.

@callumforrester callumforrester added this to the 1.0.0 milestone Nov 29, 2024
@callumforrester
Copy link
Contributor

This is a good idea and important. @fajinyuan has expressed a desire for a similar feature before.

Possible Solution

Add a mock flag to the env config, if it is True pass mock=True to make_all_devices in BlueskyContext

env:
    mock: true

Acceptance Criteria

  • There is a mock flag in config.env
  • It defaults to False
  • If it is set to True, all (ophyd-async) devices are connected in mock mode

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
devices connection enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants