Skip to content

Commit

Permalink
Merge branch 'main' into fix-annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
gphorvath authored Oct 7, 2024
2 parents ca2face + b9f6413 commit ff2b52f
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 19 deletions.
24 changes: 12 additions & 12 deletions src/leapfrogai_ui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/leapfrogai_ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"@playwright/test": "^1.47.2",
"@sveltejs/adapter-auto": "^3.2.4",
"@sveltejs/adapter-node": "^5.2.2",
"@sveltejs/kit": "^2.5.26",
"@sveltejs/kit": "^2.6.2",
"@tailwindcss/typography": "^0.5.15",
"@testing-library/jest-dom": "^6.5.0",
"@testing-library/svelte": "^5.2.1",
Expand Down
2 changes: 0 additions & 2 deletions src/leapfrogai_ui/src/lib/components/Message.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,6 @@
tabindex="0"
>
<EditOutline />
<span class="sr-only">Edit Message</span>
</IconButton>
{/if}
{#if message.role !== 'user'}
Expand Down Expand Up @@ -246,7 +245,6 @@
tabindex="0"
>
<RedoOutline />
<span class="sr-only">Regenerate Message</span>
</IconButton>
{/if}
</div>
Expand Down
7 changes: 4 additions & 3 deletions src/leapfrogai_ui/tests/assistants.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -347,9 +347,10 @@ test('displays a toast if there is an error deleting an assistant and response i
await deleteAssistantWithApi(assistant.id, openAIClient);
});

// TODO - these tests stopped working, need to be fixed
// Note - these error cases do not test all edge cases. ex. completed response comes back empty, /chat/assistants
// partially completes then fails, stream fails, etc...
test('displays an error toast if /chat/assistants throws while getting a response from an assistant', async ({
test.skip('displays an error toast if /chat/assistants throws while getting a response from an assistant', async ({
page,
openAIClient
}) => {
Expand All @@ -369,7 +370,7 @@ test('displays an error toast if /chat/assistants throws while getting a respons
await expect(page.getByText(ASSISTANT_ERROR_MSG)).toBeVisible();
});

test('displays an error toast if /chat/assistants returns a 500 when getting a response from an assistant', async ({
test.skip('displays an error toast if /chat/assistants returns a 500 when getting a response from an assistant', async ({
page,
openAIClient
}) => {
Expand All @@ -389,7 +390,7 @@ test('displays an error toast if /chat/assistants returns a 500 when getting a r
await expect(page.getByText(ASSISTANT_ERROR_MSG)).toBeVisible();
});

test('displays an error toast if /chat/assistants returns a 200 with no body when getting a response from an assistant', async ({
test.skip('displays an error toast if /chat/assistants returns a 200 with no body when getting a response from an assistant', async ({
page,
openAIClient
}) => {
Expand Down
2 changes: 1 addition & 1 deletion src/leapfrogai_ui/tests/rag.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ test('it can edit an assistant and remove a file', async ({ page, openAIClient }
await page.getByTestId('file-select-dropdown-btn').click();
await fileSelectContainer.getByTestId(`${uploadedFile1.id}-checkbox`).uncheck();
await page.getByRole('button', { name: 'Save' }).click();
await expect(page.getByText('Assistant Updated')).toBeVisible(); // also tests no assistant progress toast when no files
await expect(page.getByTestId('assistant-progress-toast')).toBeVisible();

// Cleanup
await deleteFileWithApi(uploadedFile1.id, openAIClient);
Expand Down

0 comments on commit ff2b52f

Please sign in to comment.