# -*- coding: utf-8 -*- """산출근거 스프레드시트 엔진 A — 주소 · 파서 · 우선순위 · 오류 전파 · 순환 · 딸린 칸 재계산 · 참조 옮김 엑셀 규칙표 · 명령 되돌림 짝 · 되돌리기 스택. Node 헬퍼(`helper_spreadsheet_engine.cjs`)가 TS 를 그 자리에서 트랜스파일해 돌리고 묶음마다 틀린 것 목록을 냄 — 여기서는 묶음마다 빈 목록인지 봄. 규칙표는 헬퍼 안에 있음. """ import json import os import subprocess import pytest HERE = os.path.dirname(os.path.abspath(__file__)) GROUPS = ["address", "parser", "precedence", "errors", "cycle", "graph", "refshift", "commands", "history"] @pytest.fixture(scope="module") def results(): proc = subprocess.run( ["node", os.path.join(HERE, "helper_spreadsheet_engine.cjs")], capture_output=True, text=True, encoding="utf-8", timeout=120, ) assert proc.returncode == 0, proc.stderr return json.loads(proc.stdout) @pytest.mark.parametrize("group", GROUPS) def test_묶음(results, group): assert group in results assert results[group] == []