Skip to content

Enhance MockSuperConductingMagnetController to be configurable - #2189

Merged
oliwenmandiamond merged 15 commits into
mainfrom
enhance_MockSuperConductingMagnetController
Sep 7, 2026
Merged

oliwenmandiamond merged 15 commits into
mainfrom
enhance_MockSuperConductingMagnetController

Conversation

@oliwenmandiamond

Copy link
Copy Markdown
Contributor

Fixes #2188

Instructions to reviewer on how to test:

  1. Check implementation makes sense
  2. Check tests pass

Checks for reviewer

  • Would the PR title make sense to a scientist on a set of release notes
  • If a new device has been added does it follow the standards
  • If changing the API for a pre-existing device, ensure that any beamlines using this device have updated their Bluesky plans accordingly
  • Have the connection tests for the relevant beamline(s) been run via dodal connect ${BEAMLINE}

@oliwenmandiamond
oliwenmandiamond requested a review from a team as a code owner August 25, 2026 13:59
@oliwenmandiamond oliwenmandiamond changed the title Enhance mock super conducting magnet controller Enhance MockSuperConductingMagnetController to be configurable Aug 25, 2026
@codecov

codecov Bot commented Aug 25, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.33%. Comparing base (e8b29c8) to head (bfaac63).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2189   +/-   ##
=======================================
  Coverage   99.33%   99.33%           
=======================================
  Files         367      367           
  Lines       14379    14389   +10     
=======================================
+ Hits        14284    14294   +10     
  Misses         95       95           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@oliwenmandiamond

Copy link
Copy Markdown
Contributor Author

Required for DiamondLightSource/sm-bluesky#363

@Relm-Arrowny Relm-Arrowny self-assigned this Sep 4, 2026

@Relm-Arrowny Relm-Arrowny left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Look good, but feel a bit strange to have test code as long as the actually code living in the same file, maybe we can consider moving it to MockSuperConductingMagnetController.py. Other wise I just have one Nit.

@oliwenmandiamond

Copy link
Copy Markdown
Contributor Author

Look good, but feel a bit strange to have test code as long as the actually code living in the same file, maybe we can consider moving it to MockSuperConductingMagnetController.py. Other wise I just have one Nit.

Unfortunately this is the current design in ophyd-async. The reason it has to be this way is because it is a circular dependency. This is because the mock needs to know about the device you're mocking and the device needs to attach the mock to have the default mock behaviour. Maybe this design needs to have another tweak to make it a bit more elegant

…ithub.com/DiamondLightSource/dodal into enhance_MockSuperConductingMagnetController
@oliwenmandiamond
oliwenmandiamond merged commit 9923c69 into main Sep 7, 2026
11 checks passed
@oliwenmandiamond
oliwenmandiamond deleted the enhance_MockSuperConductingMagnetController branch September 7, 2026 08:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add configurable movement simulation to i06-1 MockSuperConductingMagnetController

2 participants