Skip to content

Commit

Permalink
style: Format code
Browse files Browse the repository at this point in the history
  • Loading branch information
serverwentdown committed Oct 9, 2021
1 parent a75f04e commit 480634e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 15 deletions.
6 changes: 1 addition & 5 deletions poetry/installation/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -616,11 +616,7 @@ def _download_link(self, operation, link):
for hash_type in hash_types:
archive_hashes.add(
"{}:{}".format(
hash_type,
FileDependency(
package.name,
path,
).hash(hash_type),
hash_type, FileDependency(package.name, path).hash(hash_type),
)
)

Expand Down
12 changes: 2 additions & 10 deletions tests/installation/test_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -336,11 +336,7 @@ def test_executor_should_hash_links(config, io, pool, mocker, fixture_dir, tmp_d
.joinpath("demo-0.1.0-py2.py3-none-any.whl")
.as_uri()
)
mocker.patch.object(
Chef,
"get_cached_archive_for_link",
side_effect=lambda _: link,
)
mocker.patch.object(Chef, "get_cached_archive_for_link", side_effect=lambda _: link)

env = MockEnv(path=Path(tmp_dir))
executor = Executor(env, pool, config, io)
Expand All @@ -362,11 +358,7 @@ def test_executor_should_hash_links(config, io, pool, mocker, fixture_dir, tmp_d

def test_executor_should_hash_paths(config, io, pool, mocker, fixture_dir, tmp_dir):
link = fixture_dir("distributions").joinpath("demo-0.1.0-py2.py3-none-any.whl")
mocker.patch.object(
Chef,
"get_cached_archive_for_link",
side_effect=lambda _: link,
)
mocker.patch.object(Chef, "get_cached_archive_for_link", side_effect=lambda _: link)

env = MockEnv(path=Path(tmp_dir))
executor = Executor(env, pool, config, io)
Expand Down

0 comments on commit 480634e

Please sign in to comment.