-
Notifications
You must be signed in to change notification settings - Fork 478
Moved package into src folder and added tox for testing #154
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
Conversation
? |
|
The links above supersede the advice in the guide. They're worth a read. |
|
The guide is admittedly opinionated advice about how to structure a project and the Based on my experience it seems that putting a library in a Also, if there is a single sub-directory of Edit: I just figured out another way to replicate the issue from before, removing |
f628767 to
f9863d3
Compare
|
I like the idea. There might be consequences I'm unable to foresee right now but it sounds worth it. @theskumar What do you think? It looks like coverage computation is broken. It should probably be fixed by something like the following: diff --git a/.coveragerc b/.coveragerc
index dedbcd8..9a2049d 100644
--- a/.coveragerc
+++ b/.coveragerc
@@ -1,5 +1,5 @@
[run]
-source = dotenv/
+source = src |
|
Thank you @theskumar and @bbc2, I will fix the coverage setup and resolve the merge conflicts. I think it would make sense to have Travis run tox now for the test suite, I didn't initially work on that until I knew whether there was interest in the change. What do you think? |
|
It was a good idea to ask before investing a lot of time in this. If tox is the way to go in development, I'm also for using it in CI as this would bring the two testing environments closer together. 👍 |
|
FYI, I'm still working on updating Travis to use tox, I was just working on getting coverage working locally. |
|
Ok, I think this is ready to for review. Travis is now using the tox environments for the different versions of Python and coverage. I did have an issue with local coverage reports that was solved by removing a stale I think that as a library the dependencies in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good! Being able to run tests on various versions of Python, locally and easily, is awesome.
I'm afraid there is a conflict with master. Could you rebase and resolve it? It would be good to also squash the commits together in one commit to simplify the git history.
… installed version. Added tox to run test suite against multiple versions of Python (with coverage) and run flake8. Updated Travis CI to use tox as well. Updated documentation about running tests.
|
Apologies, I've been very busy lately but I finally got around to cleaning up this PR. Please let me know if there is anything else you would like to see. |
|
Thank you for this work. I'm merging this! |
In order to replicate issue #130 for testing purposes I had to run the tests against an installed version of dotenv on Python 2.7. I did this via moving the package into a
srcdirectory and use of tox (admittedly because that is the tool I'm familiar with).I did not change how Travis-CI runs tests but can work on that if there is traction for this change (relatedly, the combined coverage isn't working at the moment either).
Here's some other argument and background for using a
srcdirectory: