Files
payloadcms/test/helpers/folders/expectNoResultsAndCreateFolderButton.ts
Jarrod Flesch 9f0573d714 chore(ui): prevent loading orphaned documents when viewing root collection folders (#13684)
Root level collection folders should not display items, only folders. 


---
- To see the specific tasks where the Asana app for GitHub is being
used, see below:
  - https://app.asana.com/0/0/1210821658736793
2025-09-05 18:22:18 -04:00

13 lines
396 B
TypeScript

import { expect, type Page } from '@playwright/test'
type Args = {
page: Page
}
export async function expectNoResultsAndCreateFolderButton({ page }: Args): Promise<void> {
const noResultsDiv = page.locator('div.no-results')
await expect(noResultsDiv).toBeVisible()
const createFolderButton = noResultsDiv.locator('text=Create Folder')
await expect(createFolderButton).toBeVisible()
}