Skip to content

test(azure): replace large image fixtures with minimal 1x1 PNG#13487

Merged
gr2m merged 1 commit intogr2m/shrink-azure-image-fixturefrom
gr2m/shrink-azure-image-fixture-json
Mar 16, 2026
Merged

test(azure): replace large image fixtures with minimal 1x1 PNG#13487
gr2m merged 1 commit intogr2m/shrink-azure-image-fixturefrom
gr2m/shrink-azure-image-fixture-json

Conversation

@gr2m
Copy link
Copy Markdown
Collaborator

@gr2m gr2m commented Mar 16, 2026

Background

The Azure provider's image generation test fixtures contained a full 1.7MB cartoon raccoon PNG encoded as base64. This appeared in three places: the streaming chunks fixture (6.9MB), the JSON fixture (2.1MB), and the resulting snapshot (2.3MB), totaling ~11.3MB of unnecessary data. The tests only validate streaming behavior and response structure, not image content.

Follow-up to #13486 which only addressed the chunks fixture.

Summary

  • Replaced full-size base64 PNG with a minimal 1x1 pixel PNG (69 bytes) in both azure-image-generation-tool.1.chunks.txt and azure-image-generation-tool.1.json
  • Updated corresponding snapshots
File Before After
azure-image-generation-tool.1.chunks.txt 6.9 MB 12.6 KB
azure-image-generation-tool.1.json 2.1 MB 1.7 KB
azure-openai-provider.test.ts.snap 2.3 MB 200 KB
Total ~11.3 MB ~214 KB

Checklist

  • Tests have been added / updated (for bug fixes / features)
  • Documentation has been added / updated (for bug fixes / features)
  • A patch changeset for relevant packages has been added (for bug fixes / features - run pnpm changeset in the project root)
  • I have reviewed this pull request (self-review)

The azure-image-generation-tool fixtures contained a full 1.7MB raccoon
PNG as base64. The chunks fixture was 6.9MB and the JSON fixture was
2.1MB. Since the tests validate streaming behavior and response
structure, not image content, replace with a minimal 1x1 pixel PNG.

Before: chunks 6.9MB, json 2.1MB, snapshot 2.3MB (total ~11.3MB)
After:  chunks 12.6KB, json 1.7KB, snapshot 200KB (total ~214KB)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@tigent tigent bot added the ai/provider related to a provider package. Must be assigned together with at least one `provider/*` label label Mar 16, 2026
@tigent tigent bot added maintenance CI, internal documentation, automations, etc provider/azure Issues related to the @ai-sdk/azure provider labels Mar 16, 2026
@gr2m gr2m changed the base branch from main to gr2m/shrink-azure-image-fixture March 16, 2026 18:22
@gr2m gr2m merged commit 9455e24 into gr2m/shrink-azure-image-fixture Mar 16, 2026
24 checks passed
@gr2m gr2m deleted the gr2m/shrink-azure-image-fixture-json branch March 16, 2026 18:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai/provider related to a provider package. Must be assigned together with at least one `provider/*` label maintenance CI, internal documentation, automations, etc provider/azure Issues related to the @ai-sdk/azure provider

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant