mirror of
https://github.com/danielmiessler/Fabric.git
synced 2026-02-19 10:14:21 -05:00
Remove deprecated OpenAI models from image generation support list
- Remove gpt-4o, gpt-4o-mini, gpt-4.1, and gpt-4.1-mini from ImageGenerationSupportedModels - These models are being retired by OpenAI effective February 13, 2026 - Keep gpt-4.1-nano, o3, gpt-5, gpt-5-nano, gpt-5.2 as supported - Update tests to use gpt-5.2 instead of gpt-4o as the example supported model - Update test expectations to reflect deprecated models no longer being supported This ensures users get accurate warnings when attempting image generation with retired models, while maintaining support for currently available models. Co-Authored-By: Warp <agent@warp.dev>
This commit is contained in:
@@ -231,24 +231,24 @@ func TestSupportsImageGeneration(t *testing.T) {
|
||||
expected bool
|
||||
}{
|
||||
{
|
||||
name: "gpt-4o supports image generation",
|
||||
name: "gpt-4o does not support image generation (deprecated)",
|
||||
model: "gpt-4o",
|
||||
expected: true,
|
||||
expected: false,
|
||||
},
|
||||
{
|
||||
name: "gpt-4o-mini supports image generation",
|
||||
name: "gpt-4o-mini does not support image generation (deprecated)",
|
||||
model: "gpt-4o-mini",
|
||||
expected: true,
|
||||
expected: false,
|
||||
},
|
||||
{
|
||||
name: "gpt-4.1 supports image generation",
|
||||
name: "gpt-4.1 does not support image generation (deprecated)",
|
||||
model: "gpt-4.1",
|
||||
expected: true,
|
||||
expected: false,
|
||||
},
|
||||
{
|
||||
name: "gpt-4.1-mini supports image generation",
|
||||
name: "gpt-4.1-mini does not support image generation (deprecated)",
|
||||
model: "gpt-4.1-mini",
|
||||
expected: true,
|
||||
expected: false,
|
||||
},
|
||||
{
|
||||
name: "gpt-4.1-nano supports image generation",
|
||||
@@ -336,7 +336,7 @@ func TestModelValidationLogic(t *testing.T) {
|
||||
|
||||
t.Run("Supported model with image file should not trigger validation", func(t *testing.T) {
|
||||
opts := &domain.ChatOptions{
|
||||
Model: "gpt-4o",
|
||||
Model: "gpt-5.2",
|
||||
ImageFile: "/tmp/output.png",
|
||||
}
|
||||
|
||||
@@ -475,7 +475,7 @@ func TestCheckImageGenerationCompatibility(t *testing.T) {
|
||||
}{
|
||||
{
|
||||
name: "Supported model - no warning",
|
||||
model: "gpt-4o",
|
||||
model: "gpt-5.2",
|
||||
expectWarning: false,
|
||||
},
|
||||
{
|
||||
@@ -557,7 +557,7 @@ func TestSendResponses_WithWarningIntegration(t *testing.T) {
|
||||
},
|
||||
{
|
||||
name: "Supported model with image - no warning, no error",
|
||||
model: "gpt-4o",
|
||||
model: "gpt-5.2",
|
||||
imageFile: "test.png",
|
||||
expectWarning: false,
|
||||
expectError: false,
|
||||
|
||||
Reference in New Issue
Block a user