test: update divi-read-smoke.sh for node-get's short type name + rev

node-get's "type" is now the short module name ("heading"), matching
lit-divi-outline, instead of the namespaced "divi/heading"; the smoke test's
own hardcoded expectation is updated to match, and now also checks the new
post-level rev is present.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-09-26 13:12:50 +02:00
co-authored by Claude Opus 5.5
parent 45dcd9176c
commit 4356e69bb9
+2 -1
View File
@@ -64,7 +64,8 @@ pass "lit-divi-outline: path IDs, tree_rev, rev"
# 3. Node in full form plus short-form values # 3. Node in full form plus short-form values
NODE=$(tool lit-divi-node-get "{\"post_id\":$PAGE_ID,\"id\":\"s0.r0.c0.m0\"}") NODE=$(tool lit-divi-node-get "{\"post_id\":$PAGE_ID,\"id\":\"s0.r0.c0.m0\"}")
echo "$NODE" | jq -e '.type == "divi/heading" and .shortform.text == "Handwerk mit Herz"' >/dev/null || fail "node-get: $NODE" echo "$NODE" | jq -e '.type == "heading" and .shortform.text == "Handwerk mit Herz"' >/dev/null || fail "node-get: $NODE"
echo "$NODE" | jq -e '.rev | length == 12' >/dev/null || fail "node-get rev: $NODE"
echo "$NODE" | jq -e '.attrs["title.innerContent"].desktop.value == "Handwerk mit Herz"' >/dev/null || fail "node-get attrs: $NODE" echo "$NODE" | jq -e '.attrs["title.innerContent"].desktop.value == "Handwerk mit Herz"' >/dev/null || fail "node-get attrs: $NODE"
MISSING=$(tool lit-divi-node-get "{\"post_id\":$PAGE_ID,\"id\":\"s9\"}") MISSING=$(tool lit-divi-node-get "{\"post_id\":$PAGE_ID,\"id\":\"s9\"}")
[ "$(error_code "$MISSING")" = "not_found" ] || fail "unknown node: $MISSING" [ "$(error_code "$MISSING")" = "not_found" ] || fail "unknown node: $MISSING"