Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
swuecho committed Nov 26, 2023
1 parent 47d04d0 commit 0f9d85a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions e2e/tests/05_chat_session.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,13 @@ test('test', async ({ page }) => {
const session_1 = sessions_1[0];
expect(session_1.topic).toBe('test_session_topic');

await page.getByRole('button', { name: '新对话' }).click();
await page.getByRole('button', { name: 'New Chat' }).click();
await page.getByTestId('edit_session_topic').click();
await page.getByTestId('edit_session_topic_input').locator('input').click();
await page.getByTestId('edit_session_topic_input').locator('input').fill('test_session_topic_2');
await page.getByTestId('save_session_topic').click();

await page.getByRole('button', { name: '新对话' }).click();
await page.getByRole('button', { name: 'New Chat' }).click();
await page.getByTestId('edit_session_topic').click();
await page.getByTestId('edit_session_topic_input').locator('input').fill('test_session_topic_3');
await page.getByTestId('save_session_topic').click();
Expand Down
2 changes: 1 addition & 1 deletion e2e/tests/06_clear_messages.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ test('after clear conversation, only system message remains', async ({ page }) =

// clear
await page.getByRole('contentinfo').getByRole('button').first().click();
await page.getByRole('button', { name: '' }).click();
await page.getByRole('button', { name: 'Yes' }).click();

// sleep 500 ms
await page.waitForTimeout(1000);
Expand Down
2 changes: 1 addition & 1 deletion e2e/tests/09_session_answer.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ test('test', async ({ page }) => {
await page.getByTestId('signup').click();
await page.waitForTimeout(1000);

await page.locator('a').filter({ hasText: '新对话' }).click();
await page.locator('a').filter({ hasText: 'New Chat' }).click();

// set debug mode
await page.getByRole('contentinfo').getByRole('button').nth(3).click();
Expand Down
2 changes: 1 addition & 1 deletion e2e/tests/10_session_answer_regenerate.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ test('test', async ({ page }) => {
await page.getByTestId('signup').click();
await page.waitForTimeout(1000);

await page.locator('a').filter({ hasText: '新对话' }).click();
await page.locator('a').filter({ hasText: 'New Chat' }).click();

// set debug mode
await page.getByRole('contentinfo').getByRole('button').nth(3).click();
Expand Down

0 comments on commit 0f9d85a

Please sign in to comment.