Use shared formatter target choices
This commit is contained in:
@@ -2814,6 +2814,10 @@ def smoke_formatter_input_policy() -> None:
|
||||
|
||||
|
||||
def smoke_formatter_target_policy() -> None:
|
||||
_expect(
|
||||
formatter_target.target_choices() == ["auto", "single", "softcore", "hardcore"],
|
||||
"Formatter target choices changed",
|
||||
)
|
||||
_expect(formatter_target.normalize_target("single") == "single", "Formatter target lost single")
|
||||
_expect(formatter_target.normalize_target("Hard-Core") == "hardcore", "Formatter target alias lost hardcore")
|
||||
_expect(formatter_target.normalize_target("soft") == "softcore", "Formatter target alias lost softcore")
|
||||
@@ -6259,7 +6263,9 @@ def smoke_node_formatter_registration() -> None:
|
||||
caption_inputs = sxcp_nodes.NODE_CLASS_MAPPINGS["SxCPCaptionNaturalizer"].INPUT_TYPES().get("required") or {}
|
||||
_expect("caption_profile" in caption_inputs, "Caption Naturalizer lost caption_profile input")
|
||||
_expect("target" in caption_inputs, "Caption Naturalizer lost target input")
|
||||
_expect(caption_inputs["target"][0] == formatter_target.target_choices(), "Caption Naturalizer target choices drifted")
|
||||
_expect("tooltip" in caption_inputs["caption_profile"][1], "Caption profile tooltip injection missing")
|
||||
_expect(krea_inputs["target"][0] == formatter_target.target_choices(), "Krea2 Formatter target choices drifted")
|
||||
|
||||
krea_output = krea_node().build(
|
||||
"sxcppnl7 A woman standing by a window",
|
||||
@@ -6291,6 +6297,7 @@ def smoke_node_formatter_registration() -> None:
|
||||
_expect(sdxl_output[6].startswith("text("), "SDXL Formatter method changed unexpectedly")
|
||||
sdxl_inputs = sxcp_nodes.NODE_CLASS_MAPPINGS["SxCPSDXLFormatter"].INPUT_TYPES().get("required") or {}
|
||||
_expect("formatter_profile" in sdxl_inputs, "SDXL Formatter lost formatter_profile input")
|
||||
_expect(sdxl_inputs["target"][0] == formatter_target.target_choices(), "SDXL Formatter target choices drifted")
|
||||
_expect("tooltip" in sdxl_inputs["formatter_profile"][1], "SDXL formatter_profile tooltip injection missing")
|
||||
|
||||
pair = pb.build_insta_of_pair(
|
||||
|
||||
Reference in New Issue
Block a user