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

Demonstrate usage with pytest #3

Open
2 tasks
jmcgeheeiv opened this issue May 18, 2023 · 0 comments
Open
2 tasks

Demonstrate usage with pytest #3

jmcgeheeiv opened this issue May 18, 2023 · 0 comments

Comments

@jmcgeheeiv
Copy link
Owner

Commenter Charlotte Godley raised this issue in the comments of deprecated blog article https://johnnado.com/pyqt-qtest-example/. In their response, Tord added links to the pytest plugin that would be used for this.

This needs to be implemented:

  • Demonstrate running PyQt tests under pytest in the example code
  • Add a brief explanation of running PyQt tests under pytest in README.md

Charlotte Godley

October 16, 2016 @ 4:30 pm

Hey,
Re other people’s comments about unittest and pyqt, I found it much easier to fix these issues using pytest because you can scope your fixtures. Means you have to move to a whole different way of working though (injecting fixtures using parameters rather than class values).

Other thing I’m trying to work on right now is testing actions and menus, which are different because you apparently can’t use mouseClick for actions. You wouldn’t happen to know anything about that would you?

Tord replied

September 26, 2017 @ 11:47 am

Just for reference for those finding this article (thank you John for writing it), the plugin for pytest used for running tests for PyQt is called pytest-qt:

Kind Regards, Tord

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

No branches or pull requests

1 participant