mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-09-22 03:33:06 +08:00
fix(core): ai image upload failed (#13405)
Close [AI-407](https://linear.app/affine-design/issue/AI-407) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Ensured that images included in the chat context are now properly sent as attachments during AI chat interactions. * **Tests** * Enhanced chat tests to verify that the AI correctly identifies images of kittens or cats in its responses. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
@@ -36,6 +36,12 @@ test.describe('AIChatWith/Image', () => {
|
||||
status: 'success',
|
||||
},
|
||||
]);
|
||||
|
||||
const { content } = await utils.chatPanel.getLatestAssistantMessage(page);
|
||||
await expect(
|
||||
content.toLowerCase().includes('kitten') ||
|
||||
content.toLowerCase().includes('cat')
|
||||
).toBe(true);
|
||||
});
|
||||
|
||||
test('support chat with mutiple images', async ({
|
||||
|
||||
Reference in New Issue
Block a user