Expose seed control summary
This commit is contained in:
@@ -5225,6 +5225,7 @@ def smoke_node_utility_registration() -> None:
|
||||
seed_inputs = seed_control.INPUT_TYPES().get("required") or {}
|
||||
_expect("category_seed_mode" in seed_inputs, "Seed Control lost category seed mode input")
|
||||
_expect("tooltip" in seed_inputs["category_seed_mode"][1], "Seed Control tooltip injection missing")
|
||||
_expect(seed_control.RETURN_NAMES == ("seed_config", "summary"), "Seed Control lost visible summary output")
|
||||
_expect(
|
||||
node_tooltips._tooltip_for_input("SxCPSeedControl", "category_seed_mode")
|
||||
== "auto/follow_main follows the main seed; fixed uses category_seed; random rerolls this axis each queue.",
|
||||
@@ -5234,6 +5235,40 @@ def smoke_node_utility_registration() -> None:
|
||||
"Autoscaling switch input" in node_tooltips._tooltip_for_input("SxCPIndexSwitch", "input_12"),
|
||||
"Node tooltip policy lost autoscaling input fallback",
|
||||
)
|
||||
seed_control_config, seed_control_summary = seed_control().build(
|
||||
"fixed",
|
||||
-1,
|
||||
"follow_main",
|
||||
-1,
|
||||
"random",
|
||||
-1,
|
||||
"auto",
|
||||
123,
|
||||
"auto",
|
||||
-1,
|
||||
"fixed",
|
||||
777,
|
||||
"follow_main",
|
||||
888,
|
||||
"auto",
|
||||
-1,
|
||||
"fixed",
|
||||
999,
|
||||
)
|
||||
parsed_seed_control = json.loads(seed_control_config)
|
||||
_expect(parsed_seed_control.get("category_seed") == 0, "Seed Control fixed mode did not clamp negative seed")
|
||||
_expect(parsed_seed_control.get("subcategory_seed") == -1, "Seed Control follow_main mode should emit -1")
|
||||
_expect(int(parsed_seed_control.get("content_seed", -1)) >= 0, "Seed Control random mode did not emit resolved seed")
|
||||
_expect(parsed_seed_control.get("person_seed") == 123, "Seed Control auto mode did not preserve explicit value")
|
||||
_expect(parsed_seed_control.get("pose_seed") == 777, "Seed Control fixed mode did not preserve positive seed")
|
||||
_expect(parsed_seed_control.get("role_seed") == -1, "Seed Control follow_main role did not emit -1")
|
||||
_expect(parsed_seed_control.get("composition_seed") == 999, "Seed Control fixed composition seed changed")
|
||||
_expect("category=0" in seed_control_summary, "Seed Control summary lost fixed resolved seed")
|
||||
_expect("subcategory=follow_main" in seed_control_summary, "Seed Control summary lost follow_main marker")
|
||||
_expect(
|
||||
f"content={parsed_seed_control['content_seed']}" in seed_control_summary,
|
||||
"Seed Control summary lost random resolved seed value",
|
||||
)
|
||||
|
||||
seed, seed_config, summary = sxcp_nodes.NODE_CLASS_MAPPINGS["SxCPGlobalSeed"]().build(12345)
|
||||
parsed_seed = json.loads(seed_config)
|
||||
|
||||
Reference in New Issue
Block a user