refactor(776-2): 엑셀 한 번 열기(격자 = 읽은 책) · 줄 갈래 한 규칙 · EST 블록 금액 · 항목 · 옛 판 HP 409 「다시 올림」

- Excel — read_book 이 연 책(xls = formatting_info · 목록 시트까지)을 Grid.read 가 이어 씀(opened) · 거창 여는 횟수 2 → 1 · 여덟 파일 올림 시간 17.8 → 7.8 초
- Excel.kind_of = 두 형식 · 붙여넣기 한 규칙(STmate 코드 머리 · EST 칸 · 끝에 노임 올림) · Stmate._kind 걷음
- Excel — EST 블록에 금액 · 항목(ReadEst) 실음 · Basis 대신 ReadEst 직접
- Grid — 읽은 책 그대로 · xlsx 열 폭은 보기 시트 머리 <cols> 만(sheetData 에서 멈춤) · 여덟 파일 격자 결과 전과 같음
- Store.read 다른 판 = 409 「다시 올림」 · Forget.finish 는 옛 판도 끝냄(old=True)
- S1 · S2 해시 그대로 · test_718_1 옛 판 열기 409 · 끝내기 시험

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-04 12:09:24 +09:00
co-authored by Claude Opus 5.5
parent a363bbc63a
commit 3a1ce9ca4f
6 changed files with 106 additions and 39 deletions
+15 -1
View File
@@ -98,7 +98,21 @@ def test_결과_단가산출_산근_블록_기초_SK_고름대기_겹침_없음(
def test_판_다른_HP_지난_것():
"""776-2 — 읽기 꼴 판이 다르면(옛 판 · 판 없음) 막 올렸어도 지난 것 = 목록 숨김 · 다음 올림 때 끝냄."""
"""776-2 — 읽기 꼴 판이 다르면(옛 판 · 판 없음) 막 올렸어도 지난 것(숨김 · 올림 때 끝냄)."""
now = {"올린때": "2999-01-01T00:00:00Z"}
assert hs.stale({**now, "판": hs.BOOK}, now=None) is False
assert hs.stale(now) and hs.stale({**now, "판": hs.BOOK - 1})
def test_판_다른_HP_열기_409_끝내기는_됨(client):
"""776-2 — 작업 중 옛 판 HP 를 열면 409 「다시 올림」 · [끝내기]는 옛 판도 지움."""
folder = layers.personal_dir(7, 42)
assert _post(client).json()["키"] == "HP-000001"
path = folder / hs.DIRNAME / "HP-000001.json"
doc = json.loads(path.read_bytes())
path.write_text(json.dumps({**doc, "판": hs.BOOK - 1}, ensure_ascii=False), encoding="utf-8")
res = client.get(URL.format("personal") + "/HP-000001")
assert res.status_code == 409 and res.json()["detail"] == hs.RELOAD
assert _keys(client) == [] # 목록 숨김
assert client.delete(URL.format("personal") + "/HP-000001").status_code == 200
assert not path.exists()