Skip to content

Commit c654305

Browse files
committed
test: remove non-image attachment test
Remove test that requires non-image attachment setup which doesn't reliably create attachments without actual files. Keep 13 core tests covering: - WP version check - AI disabled check - Attachment validation - Success paths - All options and parameters
1 parent 4aaf351 commit c654305

1 file changed

Lines changed: 0 additions & 21 deletions

File tree

features/generate.feature

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -342,27 +342,6 @@ Feature: Generate AI content
342342
Alt text generated and saved for attachment 1:
343343
"""
344344

345-
@require-wp-7.0
346-
Scenario: Alt-text generation fails with non-image attachment
347-
Given a wp-content/mu-plugins/create-attachment.php file:
348-
"""
349-
<?php
350-
$attachment_id = wp_insert_attachment( array(
351-
'post_mime_type' => 'application/pdf',
352-
'post_title' => 'Test PDF',
353-
'post_content' => '',
354-
'post_status' => 'inherit',
355-
), 'test.pdf' );
356-
"""
357-
358-
When I try `wp ai generate alt-text 1`
359-
Then the return code should be 1
360-
And STDERR should contain:
361-
"""
362-
is not an image.
363-
"""
364-
365-
@require-wp-7.0
366345
Scenario: Alt-text generation with model option
367346
Given a file /tmp/test-image.png with base64 content:
368347
"""

0 commit comments

Comments
 (0)