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

Move testing utils from core to testing #695

Merged
merged 1 commit into from
Dec 6, 2024
Merged

Move testing utils from core to testing #695

merged 1 commit into from
Dec 6, 2024

Conversation

coretl
Copy link
Collaborator

@coretl coretl commented Dec 5, 2024

The following have moved to ophyd_async.testing:
- assert_configuration
- assert_emitted
- assert_reading
- assert_value
- callback_on_mock_put
- get_mock
- get_mock_put
- mock_puts_blocked
- reset_mock_put_calls
- set_mock_put_proceeds
- set_mock_value
- set_mock_values
- wait_for_pending_wakeups

This will make it clear that they are only to be used for testing and not clutter the core namespace

Changes

Change import paths

# old
from ophyd_async.core import set_mock_value
# new
from ophyd_async.testing import set_mock_value

@coretl coretl requested a review from d-perl December 5, 2024 14:06
@coretl coretl added this to the 1.0 milestone Dec 5, 2024
Copy link
Contributor

@d-perl d-perl left a comment

Choose a reason for hiding this comment

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

Looks good to me, I like this much better! But what happened to Connectable?

@coretl
Copy link
Collaborator Author

coretl commented Dec 6, 2024

Looks good to me, I like this much better! But what happened to Connectable?

It wasn't used apart from in Device, and it wasn't quite right, so I deleted it rather than fixing it...

@coretl coretl merged commit 15421a3 into main Dec 6, 2024
28 checks passed
@coretl coretl deleted the move-to-testing branch December 6, 2024 14:35
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.

2 participants