Merge pull request #25269 from overleaf/td-flaky-tags-test

Add waits for flaky tag list test

GitOrigin-RevId: 9d0bf2acd54d07e96fe6837296176e62bf981947
This commit is contained in:
Tim Down
2025-05-06 11:53:20 +01:00
committed by Copybot
parent 42eb4b2779
commit aa97dbdbb6

View File

@@ -41,20 +41,20 @@ describe('<TagsList />', function () {
fetchMock.removeRoutes().clearHistory()
})
it('displays the tags list', function () {
const header = screen.getByTestId('organize-projects')
it('displays the tags list', async function () {
const header = await screen.findByTestId('organize-projects')
expect(header.textContent).to.equal('Organize Tags')
screen.getByRole('button', {
await screen.findByRole('button', {
name: 'New Tag',
})
screen.getByRole('button', {
await screen.findByRole('button', {
name: 'Tag 1 (1)',
})
screen.getByRole('button', {
await screen.findByRole('button', {
name: 'Another tag (2)',
})
screen.getByRole('button', {
await screen.findByRole('button', {
name: 'Uncategorized (3)',
})
})