-
-
Notifications
You must be signed in to change notification settings - Fork 2
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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
馃И more tests #45
馃И more tests #45
Conversation
@@ -122,6 +122,7 @@ def pip_compile_cli(self) -> None: | |||
""" | |||
if not self.dependencies: | |||
self.piptools_lock_file.unlink(missing_ok=True) | |||
self.lockfile_up_to_date = True |
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 is the only material code change of the PR - it was added to resolve test_delete_dependencies
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.
I don't think I'll be able to properly look at this in the next days, but just had a small comment anyway
|
||
import pytest | ||
import tomlkit |
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.
Add tomlkit to test dependencies?
hatch-pip-compile/pyproject.toml
Line 121 in f7d9dad
dependencies = [ |
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.
tomlkit came along with hatch, do you think it's worth it to declare as a dep?
hatch-pip-compile/requirements/requirements-test.txt
Lines 177 to 180 in f7d9dad
tomlkit==0.12.3 | |
# via | |
# -c requirements.txt | |
# hatch |
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.
We put things into dependencies when we use them, we don't just skip dependencies because something somewhere happens to pull it in at the moment. Hatch does not have a documented feature "provide tomlkit" and it could reasonably stop using that library any time.
馃帀 This PR is included in version 1.8.3 馃帀 The release is available on GitHub release Your semantic-release bot 馃摝馃殌 |
This PR includes a new all-in-one testing fixture,
pip_compile
(PipCompileFixture
) that can be used throughout the tests.This PR also includes a number of new tests, including what I'm calling "integration tests" at
tests/test_integration.py
. These tests ultimately make calls topip-tools
/pip
and create their own virtual environments inside the testing isolation temp dirs.Closes #18