-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Breakout argument parser functions for package name and version
- Loading branch information
1 parent
c176265
commit 316c43a
Showing
2 changed files
with
29 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,14 @@ | ||
import json | ||
|
||
from ethpm_cli._utils.ipfs import pin_local_manifest | ||
|
||
|
||
def test_pin_local_manifest(test_assets_dir): | ||
local_manifest_path = test_assets_dir / "owned" / "1.0.0.json" | ||
expected_manifest = json.loads( | ||
local_manifest_path.read_text() | ||
expected_manifest = json.loads(local_manifest_path.read_text()) | ||
(package_name, package_version, manifest_uri) = pin_local_manifest( | ||
local_manifest_path | ||
) | ||
(package_name, package_version, manifest_uri) = pin_local_manifest(local_manifest_path) | ||
assert package_name == expected_manifest["package_name"] | ||
assert package_version == expected_manifest["version"] | ||
assert manifest_uri == "ipfs://QmbeVyFLSuEUxiXKwSsEjef6icpdTdA4kGG9BcrJXKNKUW" |