Initial commit: VMware vSphere API simulator scaffold.

Add the FastAPI app, PostgreSQL migrations, Docker/Helm packaging, API
contracts, docs, client examples, and the unit/integration/compatibility
test suite for local client and tooling labs without a real vCenter.
This commit is contained in:
2026-07-18 04:42:11 +03:00
commit f8d3cbdd59
422 changed files with 361335 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
"""Offline checks for the researched API Viewer sample."""
import hashlib
import json
from pathlib import Path
from typing import Any, cast
import pytest
pytestmark = pytest.mark.pve_stub
FIXTURES = Path(__file__).parents[1] / "fixtures" / "api-viewer"
def test_version_fixture_matches_provenance() -> None:
fixture_path = FIXTURES / "pve-9.2.3-version.json"
provenance_path = FIXTURES / "pve-9.2.3-version.provenance.json"
fixture_bytes = fixture_path.read_bytes()
fixture = cast(dict[str, Any], json.loads(fixture_bytes))
provenance = cast(dict[str, Any], json.loads(provenance_path.read_bytes()))
assert fixture["path"] == "/version"
assert fixture["info"]["GET"]["method"] == "GET"
assert hashlib.sha256(fixture_bytes).hexdigest() == provenance["fixture_sha256"]