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

Fixes test_p4a_recommended_android_ndk_found() mocking #983

Merged
merged 1 commit into from
Oct 5, 2019

Conversation

AndreMiras
Copy link
Member

Mocking for line in open() should be done via StringIO.
Also uses pytest in tox.ini so assert errors are more verbose.

Mocking `for line in open()` should be done via `StringIO`.
Also uses `pytest` in `tox.ini` so assert errors are more verbose.
try:
from unittest import mock # Python 3
except ImportError:
import mock # Python 2
Copy link
Member Author

Choose a reason for hiding this comment

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

I know you guys like it this way, so I reintroduced it 😄

deps =
mock
pytest
commands = pytest tests/
Copy link
Member Author

Choose a reason for hiding this comment

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

Basically pytest makes it possible to see exact result of failing comparison. That way we don't need to debug print around in Travis 😉

Copy link
Member

@inclement inclement left a comment

Choose a reason for hiding this comment

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

Nice, thanks.

@inclement inclement merged commit 81c31c4 into kivy:master Oct 5, 2019
@AndreMiras AndreMiras deleted the feature/minor_tests_improvements branch October 5, 2019 17:36
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