"""master_copy 펴기 · 되돌리기 왕복(PLAN 3-4) — 로직 전부가 펴고 되돌리면 원래 식 글자 그대로. M01 [복사/생성] 옛 시트 길(`/logic/formula*`)은 855 L3 ⓐ 에서 걷음(문서 복제 = `test_854_2_m01_copy_doc`) · `master_copy` 는 M02 `Sangeun_Formula` · `master_text` 가 아직 씀 — 로직 JSON 을 걷는 둘째 박자에서 이 시험도 걷음. """ from __future__ import annotations import sys from pathlib import Path from M01_MasterData import M01_MasterData_Store as store sys.path.insert(0, str(Path(__file__).resolve().parents[1] / "master_data/scripts")) import master_copy as mcp # noqa: E402 REAL = store.FOLDER def test_로직_전부가_펴고_되돌리면_원래_식으로_돌아온다() -> None: files = store.cm.load(folder=REAL) master = store.cm.mf.Master(files) bad, rows = [], 0 for data in files.values(): if data.get("그룹") != "로직": continue for row in data.get("줄") or []: rows += 1 bad += mcp.check(master, row) assert rows > 1000, rows assert not bad, bad[:5]