Files
ComfyUI-H3-Continuum-Tiled/tests/conftest.py
T
ukr8b3g-cmyk 190141e03e fix: stabilize V3.9 and bump package to 3.9.1
Preserve Second Pass audio and scoped Review conditioning, strengthen Take compatibility, and align Review Driving Audio.

Keep v5 history readable, document v6 restart requirements, and describe the fixes at the top of both READMEs. Remove workstation-specific paths and private operational records from public documentation.
2026-10-04 19:05:33 +09:00

44 lines
1.4 KiB
Python

from __future__ import annotations
import importlib.util
import sys
from pathlib import Path
ROOT = Path(__file__).resolve().parents[1]
PACKAGE_NAME = "ComfyUI_H3_Continuum_Join"
if PACKAGE_NAME not in sys.modules:
spec = importlib.util.spec_from_file_location(
PACKAGE_NAME,
ROOT / "__init__.py",
submodule_search_locations=[str(ROOT)],
)
module = importlib.util.module_from_spec(spec)
module.__path__ = [str(ROOT)]
sys.modules[PACKAGE_NAME] = module
# Run real production JS through ComfyUI's supported queue lifecycle once.
# No unsupported beforeQueuePrompt helper injection or copied UI predicates.
import json
import os
import shutil
import subprocess
import pytest
@pytest.fixture(scope="session")
def review_queue_results():
node = shutil.which("node")
assert node, "Node.js is required for the frontend regression gate"
result = subprocess.run(
[node, str(ROOT / "tests" / "frontend_review_queue.cjs")],
env={**os.environ, "H3_TEST_ROOT": str(ROOT)},
capture_output=True, text=True, encoding="utf-8", timeout=45,
)
records = json.loads(result.stdout)
assert len(records) == 62, "The complete queue fixture must finish, including Workflow rehydration and v5 history"
failures = [item for item in records if not item["pass"]]
assert result.returncode == 0 and not failures, result.stdout + result.stderr
return {item["name"]: item for item in records}