mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-18 23:07:02 +08:00
@@ -261,7 +261,7 @@ export class CopilotContextDocJob {
|
|||||||
): Promise<DocFragment | null> {
|
): Promise<DocFragment | null> {
|
||||||
const docContent = await this.doc.getFullDocContent(workspaceId, docId);
|
const docContent = await this.doc.getFullDocContent(workspaceId, docId);
|
||||||
const authors = await this.models.doc.getAuthors(workspaceId, docId);
|
const authors = await this.models.doc.getAuthors(workspaceId, docId);
|
||||||
if (docContent?.summary && authors) {
|
if (docContent && authors) {
|
||||||
const { title = 'Untitled', summary } = docContent;
|
const { title = 'Untitled', summary } = docContent;
|
||||||
const { createdAt, updatedAt, createdByUser, updatedByUser } = authors;
|
const { createdAt, updatedAt, createdByUser, updatedByUser } = authors;
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -28,7 +28,9 @@ test.describe('AIBasic/Chat', () => {
|
|||||||
await check.hover();
|
await check.hover();
|
||||||
const tooltip = await page.getByTestId('ai-chat-embedding-status-tooltip');
|
const tooltip = await page.getByTestId('ai-chat-embedding-status-tooltip');
|
||||||
await expect(tooltip).toBeVisible();
|
await expect(tooltip).toBeVisible();
|
||||||
await expect(tooltip).toHaveText(/Results will improve after embedding/i);
|
await expect(tooltip).toHaveText(
|
||||||
|
/Results will improve after embedding|Embedding finished/
|
||||||
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
test(`should send message and receive AI response:
|
test(`should send message and receive AI response:
|
||||||
|
|||||||
Reference in New Issue
Block a user