Skip to content

feat(tests/conformance): add image-generation conformance suite#73

Merged
lIang70 merged 2 commits into
mainfrom
feat/conformance-image-tests
May 7, 2026
Merged

feat(tests/conformance): add image-generation conformance suite#73
lIang70 merged 2 commits into
mainfrom
feat/conformance-image-tests

Conversation

@lIang70

@lIang70 lIang70 commented May 7, 2026

Copy link
Copy Markdown
Collaborator

Summary

Live-API conformance scenarios for the three image-generation
adapters that landed in sdkx/v0.2.6 via #72:
minimax-image / bytedance-image / qwen-image.

Each test self-skips when its FLOWCRAFT_TEST_*_IMAGE env var is
unset, so credential-less runs (CI default) are a no-op. Same
pattern as the existing chat conformance suite.

Scenarios

# Test Coverage
1 BasicTextToImage Smoke for every adapter
2 ExplicitDimensions Width/Height routing — WxH (MiniMax / Seedream) vs W*H (Qwen)
3 Streaming NewOneChunkStream contract: single chunk + final message
4 ImageToImage Reference-image input (minimax / bytedance only)
5 QwenRejectsImageInput Pins the t2i-only contract

Optional offline review

SAVE_GENERATED_IMAGES=1 make test-conformance downloads every
returned image into tests/conformance/llm/_out/ (git-ignored)
for visual inspection. Off by default, so CI / credential-less
runs stay disk-clean.

Dependency / replace housekeeping

Bonus housekeeping (separate commit)

chore(.gitignore): relocate per-example binary ignores — moves
examples/voice-pipeline/voice-pipeline and
examples/chatbot-with-recall/chatbot-with-recall from the
top-level .gitignore into a new examples/.gitignore so future
examples can manage their build artefacts in isolation. Net
behaviour identical.

Test plan

  • cd tests/conformance && GOWORK=off go vet ./...
  • cd tests/conformance && GOWORK=off go test -count=1 ./...
    (creds-less, all skip cleanly)
  • Live run against my keys with all five scenarios green;
    SAVE_GENERATED_IMAGES=1 produced and visually verified the
    11 sample images.

Made with Cursor

lIang70 and others added 2 commits May 7, 2026 18:48
Live-API conformance scenarios for the three image-generation
adapters added in sdkx v0.2.6 (#72): minimax-image, bytedance-image,
qwen-image. Each test self-skips when its FLOWCRAFT_TEST_*_IMAGE
env var is unset, so credential-less runs are a no-op (matches the
chat conformance pattern).

Five scenarios across the three providers:

- Basic text-to-image (all three).
- Explicit Width/Height routing — verifies the per-family size
  syntax (WxH for MiniMax/Seedream, W*H for Qwen) and known-valid
  dimensions per provider (1024x1024 / 2048x2048 / 1024x1024).
- Streaming via NewOneChunkStream — validates the StreamMessage
  contract (single chunk + final message carrying image parts).
- Image-to-image with a reference URL (minimax-image,
  bytedance-image; reference image hosted on Aliyun help-static
  CDN so it stays reachable from China-region inference servers).
- qwen-image rejection of PartImage inputs — pins the t2i-only
  contract; image editing lives on a separate qwen-image-edit
  endpoint not yet adapted.

Optional offline review path: setting SAVE_GENERATED_IMAGES=1
downloads every returned image to tests/conformance/llm/_out/
(directory git-ignored) for visual inspection. Off by default so
CI and credential-less runs stay disk-clean.

Bumps the conformance module's sdk pin to v0.2.8 (#71) and sdkx
pin to v0.2.6 (#72), and drops the local replace directives that
were temporarily added while those PRs were in flight. The module
now exclusively tests against released versions, restoring the
README's stated "isolate dependency graph from sdk/sdkx releases"
property.

Co-authored-by: Cursor <cursoragent@cursor.com>
…itignore

Tiny housekeeping: the per-example ignores
  examples/voice-pipeline/voice-pipeline
  examples/chatbot-with-recall/chatbot-with-recall
were lodged at the repo root, which couples adding/renaming an
example with editing the top-level .gitignore. Moves them into a
local examples/.gitignore so future examples can manage their
build artefacts in isolation.

Net behaviour identical.

Co-authored-by: Cursor <cursoragent@cursor.com>
@lIang70
lIang70 merged commit a58e900 into main May 7, 2026
10 checks passed
@lIang70
lIang70 deleted the feat/conformance-image-tests branch May 7, 2026 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant