def test_gitlab_full_serialize(): gitlab = storage.GitLab( repo="test/repo", path="path/to/flow.py", host="http://localhost:1234", ref="test-branch", secrets=["token"], )
def test_gitlab_empty_serialize(): gitlab = storage.GitLab(repo="test/repo") serialized = GitLabSchema().dump(gitlab) assert serialized["__version__"] == prefect.__version__ assert serialized["repo"] == "test/repo" assert not serialized["host"] assert not serialized["path"] assert not serialized["ref"] assert serialized["secrets"] == []
def test_gitlab_full_serialize(): gitlab = storage.GitLab( repo="test/repo", path="path/to/flow.py", host="http://localhost:1234", ref="test-branch", secrets=["token"], ) serialized = GitLabSchema().dump(gitlab) assert serialized["__version__"] == prefect.__version__ assert serialized["repo"] == "test/repo" assert serialized["host"] == "http://localhost:1234" assert serialized["path"] == "path/to/flow.py" assert serialized["ref"] == "test-branch" assert serialized["secrets"] == ["token"]
def test_gitlab_empty_serialize(): gitlab = storage.GitLab(repo="test/repo")