Skip to content

Commit

Permalink
relax schema for git dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
dimbleby committed Oct 31, 2023
1 parent 1156165 commit ec7e806
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 1 addition & 2 deletions src/poetry/core/json/schemas/poetry-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -362,8 +362,7 @@
"properties": {
"git": {
"type": "string",
"description": "The url of the git repository.",
"format": "uri"
"description": "The url of the git repository."
},
"branch": {
"type": "string",
Expand Down
4 changes: 4 additions & 0 deletions tests/json/test_poetry_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ def test_path_dependencies(base_object: dict[str, Any]) -> None:
def test_multi_url_dependencies(multi_url_object: dict[str, Any]) -> None:
assert len(validate_object(multi_url_object, "poetry-schema")) == 0

def test_git_dependencies(base_object: dict[str, Any]) -> None:
base_object["dependencies"].update({"git-dependency": {"git": "[email protected]:example/example-repository.git"}})

assert len(validate_object(base_object, "poetry-schema")) == 0

@pytest.mark.parametrize(
"bad_description",
Expand Down

0 comments on commit ec7e806

Please sign in to comment.