feat(integration-tests): add tests for uncovered UI features#5995
feat(integration-tests): add tests for uncovered UI features#5995theosanderson-agent wants to merge 1 commit intomainfrom
Conversation
…atures Add integration tests for features discovered through browser exploration that had no existing test coverage: API documentation page, 404 error pages, landing page organism statistics, footer navigation links, header accession quick-search, sequence detail page metadata sections, search table column sorting, Tools/link-out menu, and advanced search options modal. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
This PR adds 23 new integration tests covering previously untested UI features. The following open issues appear related to the work here and may be worth referencing or considering:
None of these issues appear to be directly resolved by this PR, but they represent related work in the integration test area. |
| import { test } from '../../../fixtures/console-warnings.fixture'; | ||
| import { SearchPage } from '../../../pages/search.page'; | ||
|
|
||
| test.describe('Search table sorting', () => { |
There was a problem hiding this comment.
I wonder if this could be flaky - can we wait for there to be multiple sequences? also potentially the first sequence will by chance be the earliest, maybe we should actually compare the date?
| await searchPage.ebolaSudan(); | ||
|
|
||
| const rows = searchPage.getSequenceRows(); | ||
| await rows.first().waitFor(); |
There was a problem hiding this comment.
I guess also here, should we ensure there are multiple sequences?
| .or(page.getByText(/does not exist/i)) | ||
| .or(page.getByText(/error/i)) |
There was a problem hiding this comment.
| .or(page.getByText(/does not exist/i)) | |
| .or(page.getByText(/error/i)) |
| test('should display error for non-existent sequence accession', async ({ page }) => { | ||
| await page.goto('/seq/LOC_NONEXISTENT.1'); | ||
|
|
||
| // The page may render with 200 but show an error message |
| test('should display error for non-existent sequence accession', async ({ page }) => { | ||
| await page.goto('/seq/LOC_NONEXISTENT.1'); | ||
|
|
||
| // The page may render with 200 but show an error message |
There was a problem hiding this comment.
| // The page may render with 200 but show an error message | |
| // The page should render with 200 but show an error message |
| await detailPage.goto(accessionVersion); | ||
|
|
||
| await expect(page.getByText('Sample details')).toBeVisible(); | ||
| await expect(page.getByText('Collection date')).toBeVisible(); |
There was a problem hiding this comment.
this might also flake as certain INSDC sequences do not have a collection date
anna-parker
left a comment
There was a problem hiding this comment.
looks good! I added a couple comments of where I think the tests could get flaky and should be modified but I have still approved as I think this is an overall improvement :-)

Summary
New test coverage areas:
api-documentation-page.spec.tserror-pages.spec.tslanding-page-statistics.spec.tsfooter-links.spec.tsheader-accession-search.dependent.spec.tssequence-detail-metadata.dependent.spec.tssearch/table-sorting.dependent.spec.tssearch/tools-link-out.dependent.spec.tssearch/advanced-options.dependent.spec.tsTest plan
BROWSER=chromium npx playwright testagainst local k3dnpm run format)🤖 Generated with Claude Code
🚀 Preview: Add
previewlabel to enable