Skip to content

Commit

Permalink
Fix micropkg tests
Browse files Browse the repository at this point in the history
Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>
  • Loading branch information
astrojuanlu committed Jun 13, 2023
1 parent f39a024 commit fde96bb
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tests/framework/cli/micropkg/test_micropkg_pull.py
Expand Up @@ -600,6 +600,17 @@ def test_pull_from_pypi(
return_value=tmp_path,
)

# Mock needed to avoid an error when build.util.project_wheel_metadata
# calls tempfile.TemporaryDirectory, which is mocked
class _FakeWheelMetadata:
def get_all(self, name, failobj=None):
return []

mocker.patch(
"kedro.framework.cli.micropkg.project_wheel_metadata",
return_value=_FakeWheelMetadata(),
)

options = ["-e", env] if env else []
options += ["--alias", alias] if alias else []

Expand Down

0 comments on commit fde96bb

Please sign in to comment.