fix(canvas): 局部重绘、图片规格与任务参数修复
This commit is contained in:
1 parent
bacd502f5c
commit
cd2ad4d700
13 files changed
+124
-45
No files matched your search
@@ -38,6 +38,19 @@ func TestImagePriceTiersMatchResolutionAndActualReferences(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestAutoQualityIsOmittedFromCapabilityIntent(t *testing.T) {
|
||||
intent := ModelRequestIntentFromTaskInput(map[string]any{
|
||||
"mode": "image",
|
||||
"capabilityOptions": map[string]any{"quality": "auto", "size": "2048x878"},
|
||||
}, "canvas_image", "image")
|
||||
if _, exists := intent.Options["quality"]; exists {
|
||||
t.Fatalf("quality option = %#v, want omitted for auto", intent.Options["quality"])
|
||||
}
|
||||
if intent.Options["size"] != "2048x878" {
|
||||
t.Fatalf("size option = %#v, want preserved", intent.Options["size"])
|
||||
}
|
||||
}
|
||||
|
||||
func TestModelRequestIntentNormalizesVideoResolution(t *testing.T) {
|
||||
input := map[string]any{
|
||||
"mode": "video",
|
||||
|
||||
Reference in new issue
Block a user