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

Change test_data_path and unicode conf #53

Merged
merged 2 commits into from Nov 9, 2018

Conversation

gnott
Copy link
Member

@gnott gnott commented Nov 1, 2018

Planning to initialise a new code repo, I thought I would switch to using pytest, so I tried to run the tests on this library.

After some amount of troubleshooting, I found it was picking up on the test_data_path() function thinking it was some sort of test fixture, which it is not. That function is renamed here.

pytest also displayed warnings about bytecode values being explicitly converted to unicode in the configparser usage, and I set those values to unicode strings to avoid the warnings.

Not a critical PR, but it means this library will be pytest compatible if merged.

@coveralls
Copy link

Pull Request Test Coverage Report for Build 159

  • 31 of 31 (100.0%) changed or added relevant lines in 11 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 99.907%

Totals Coverage Status
Change from base Build 157: 0.0%
Covered Lines: 1075
Relevant Lines: 1076

💛 - Coveralls

@@ -34,6 +34,6 @@ def read_fixture(filename, folder_name=''):
with open(full_filename, 'rb') as file_fp:
return file_fp.read()

def test_data_path(file_name):
def data_path(file_name):
Copy link
Contributor

Choose a reason for hiding this comment

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

I think test_ prefixes are auto-detected as being test functions

Copy link
Contributor

@giorgiosironi giorgiosironi left a comment

Choose a reason for hiding this comment

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

pytest is a good de-facto standard

@gnott gnott merged commit 9f36477 into develop Nov 9, 2018
@gnott gnott deleted the feature-test-data-path-and-unicode-conf branch December 18, 2018 00:25
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.

None yet

3 participants