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

Replace unit tests marked by the @pytest.mark.local decorator. #810

Closed
prjemian opened this issue Feb 17, 2023 · 3 comments · Fixed by #954
Closed

Replace unit tests marked by the @pytest.mark.local decorator. #810

prjemian opened this issue Feb 17, 2023 · 3 comments · Fixed by #954
Assignees
Labels
Milestone

Comments

@prjemian
Copy link
Contributor

prjemian commented Feb 17, 2023

Replace the three tests. For now, restore the @pytest.mark.local decorator. As noted in #809, the current tests do not reveal if there is a problem with the apstools.devices.positioner_soft_done or the tests themselves. Refactor with simpler tests that are focused on features of the support, as noted in #810.

Originally posted by @prjemian in #748 (comment)

@prjemian prjemian added this to the 1.6.15 milestone Feb 17, 2023
@prjemian prjemian self-assigned this Feb 17, 2023
@prjemian prjemian changed the title Replace the three tests marked by the @pytest.mark.local decorator. Replace unit tests marked by the @pytest.mark.local decorator. Feb 17, 2023
@prjemian
Copy link
Contributor Author

Focus on creating tests for lines of code not already covered by tests. Coverage of positioner_soft_done.py shows these lines needs test coverage:

if not self.inposition:
self.setpoint.put(self.position)
timed_pause()
self.cb_readback() # re-evaluate soft done Signal

@prjemian
Copy link
Contributor Author

prjemian commented Apr 4, 2024

No test failures in the recent CI. Even with the local marks commented out. That's encouraging!

Still, this line fails sometimes (local or CI):

assert pos.setpoint.get(use_monitor=False) == rb_mid # FIXME: fails sometimes 1.0 == 0.5

prjemian added a commit that referenced this issue Apr 4, 2024
prjemian added a commit that referenced this issue Apr 4, 2024
prjemian added a commit that referenced this issue Apr 4, 2024
prjemian added a commit that referenced this issue Apr 9, 2024
@prjemian
Copy link
Contributor Author

prjemian commented Jul 9, 2024

While these tests are now succeeding, the fix is part of #954.

@prjemian prjemian modified the milestones: 1.6.20, 1.6.21 Jul 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant