Skip to content

Align WhatsApp tests with current channel behavior#29

Merged
erik-mingyang merged 1 commit intoRunchuan-BU:mainfrom
zongtingwei:fix/whatsapp-test-alignment
Mar 25, 2026
Merged

Align WhatsApp tests with current channel behavior#29
erik-mingyang merged 1 commit intoRunchuan-BU:mainfrom
zongtingwei:fix/whatsapp-test-alignment

Conversation

@zongtingwei
Copy link
Copy Markdown
Contributor

Summary

This PR updates src/channels/whatsapp.test.ts to match the current WhatsApp channel implementation.

Specifically, it:

  • adds the config mock exports now used by the runtime (ALLOW_WHATSAPP_SELF_MESSAGES, ASSISTANT_NAME, and GROUPS_DIR)
  • adds Baileys mocks for media download and version lookup used by the current channel implementation
  • updates onChatMetadata assertions to the current three-argument callback shape
  • updates the image-message assertion to match the current content-building behavior

Validation

Ran locally:

  • npx vitest run src/channels/whatsapp.test.ts
  • npx vitest run

Both passed locally.

@erik-mingyang erik-mingyang merged commit 60afa0b into Runchuan-BU:main Mar 25, 2026
2 checks passed
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.

2 participants