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

Improve automated tests support on Windows #300

Merged
merged 9 commits into from Mar 8, 2021

Conversation

Peilonrayz
Copy link
Contributor

This fixes the majority of #298. Most of the changes should be self-explanatory.
However, I have changed coverage to combine the output as a 3.8 specific coverage bug was causing cover to fail.

I have not fixed Docs.3 as I'm unsure how I should fix it, this means docs is still failing.

def test_create_interpreter(make_one):
venv, dir_ = make_one(interpreter="python3")
interpreter = "3.7" if IS_WINDOWS else "python3"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can we make this work regardless of which Python version we're testing with?

@Peilonrayz
Copy link
Contributor Author

Peilonrayz commented Mar 26, 2020 via email

@theacodes
Copy link
Collaborator

I would prefer a single session (like tests-3.6) be able to pass if only that interpreter is installed. Does that make sense?

@Peilonrayz
Copy link
Contributor Author

Peilonrayz commented Mar 30, 2020 via email

@theacodes
Copy link
Collaborator

Yes, the test should either pass or skip. I can't see why this test can't be changed to work with whatever python version the tests are currently running under.

@Peilonrayz
Copy link
Contributor Author

Peilonrayz commented Mar 30, 2020 via email

@theacodes
Copy link
Collaborator

theacodes commented Mar 30, 2020 via email

Base automatically changed from master to main February 11, 2021 23:24
@theacodes
Copy link
Collaborator

Howdy, @Peilonrayz. It looks like this PR has gone stale. If you're still interested in getting it merged, let me know and we can get this started again.

@theacodes theacodes closed this Mar 7, 2021
@Peilonrayz
Copy link
Contributor Author

Sorry life got busy. I've looked into the problem again and make_one(interpreter="python3") fails to resolve to an interpreter for me. Maybe I have a bug with my setup or nox has a bug making the test fail. I have gotten make_one(interpreter=None) to work on Windows but I'd just be adding a potential bug on Linux since the assert dir_.join("bin", "python3").check() could fail if Python 2 is used. I could use make_one(interpreter=None if IS_WINDOWS else "python3"), which smells to me.

Bottom line; I don't know how to nicely solve the issue we have here.

Would the best course of action be to just remove the changes to test_create_interpreter and let the rest of the PR through?

@theacodes
Copy link
Collaborator

theacodes commented Mar 7, 2021 via email

@Peilonrayz
Copy link
Contributor Author

Ok! I've undone the changes to test_create_interpreter, but the commit isn't showing up here for me. This is my first time working on a closed PR; do I need to create a new PR?

@theacodes theacodes reopened this Mar 8, 2021
@theacodes
Copy link
Collaborator

I re-opened it. Looks like you may need to git push though?

@Peilonrayz
Copy link
Contributor Author

Thank you for reopening my PR. FWIW I edited the file on GitHub and when I got to the issue today the commit had appeared here.

I had to merge some changes, for the most part I took your changes. Where I kept coverage combine to fix a bug in Python that affects coverage on Windows. Since I can't reproduce the issue - you may have changed the one bit of code which had the bug. I'm happy to remove the call to coverage combine if you'd like.

@theacodes theacodes merged commit 082c266 into wntrblm:main Mar 8, 2021
@theacodes
Copy link
Collaborator

Thank you!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants