mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-05-11 16:30:57 +00:00
## Summary Add E2E tests for node templates ## Changes - **What**: - add tests for save, insert, delete, import export - vue and litegraph - add testid to dialog - update `clickLitegraphMenuItem` to enable clicking children with the same name as parent ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-11564-test-e2e-coverage-for-node-templates-34b6d73d365081a39ce5c713f05a2a92) by [Unito](https://www.unito.io)
20 lines
644 B
TypeScript
20 lines
644 B
TypeScript
import { comfyPageFixture } from '@e2e/fixtures/ComfyPage'
|
|
import { NodeTemplatesHelper } from '@e2e/fixtures/helpers/NodeTemplatesHelper'
|
|
import { UserDataHelper } from '@e2e/fixtures/helpers/UserDataHelper'
|
|
|
|
export const nodeTemplatesFixture = comfyPageFixture.extend<{
|
|
nodeTemplates: NodeTemplatesHelper
|
|
}>({
|
|
nodeTemplates: async ({ comfyPage }, use) => {
|
|
const userData = new UserDataHelper(
|
|
comfyPage.request,
|
|
comfyPage.id,
|
|
comfyPage.url
|
|
)
|
|
const helper = new NodeTemplatesHelper(comfyPage, userData)
|
|
await helper.reset()
|
|
await comfyPage.workflow.reloadAndWaitForApp()
|
|
await use(helper)
|
|
}
|
|
})
|