mirror of
https://github.com/barsdeveloper/ueblueprint.git
synced 2026-05-19 12:27:39 +08:00
Fixing mirrored ExportPath
This commit is contained in:
16
tests/fixtures/BlueprintFixture.js
vendored
16
tests/fixtures/BlueprintFixture.js
vendored
@@ -106,14 +106,14 @@ export default class BlueprintFixture {
|
||||
|
||||
async setup() {
|
||||
const url = `http://127.0.0.1:${this.#port}/empty.html`
|
||||
try {
|
||||
await this.page.goto(url)
|
||||
} catch (e) {
|
||||
if (e.message.includes("ERR_CONNECTION_REFUSED")) {
|
||||
await this.createServer()
|
||||
await this.page.goto(url)
|
||||
} else {
|
||||
throw e
|
||||
for (let i = 0; i < 1E4; ++i) {
|
||||
try {
|
||||
await this.page.goto(url, { waitUntil: "domcontentloaded" })
|
||||
break
|
||||
} catch (e) {
|
||||
if (e.message.includes("ERR_CONNECTION_REFUSED")) {
|
||||
await this.createServer()
|
||||
}
|
||||
}
|
||||
}
|
||||
this.#blueprintLocator = this.page.locator("ueb-blueprint")
|
||||
|
||||
6
tests/fixtures/test.js
vendored
6
tests/fixtures/test.js
vendored
@@ -42,7 +42,7 @@ export const test = /**
|
||||
}
|
||||
)
|
||||
|
||||
test.setTimeout(3000)
|
||||
test.setTimeout(10000)
|
||||
|
||||
export const expect = base.expect
|
||||
export * from "@playwright/test"
|
||||
@@ -194,8 +194,8 @@ export function testNode(testData) {
|
||||
async ({ blueprintPage }) => {
|
||||
const variadic = blueprintPage.node.getByText("Add pin")
|
||||
await expect(variadic).toBeVisible()
|
||||
await variadic.hover({ timeout: 1000 })
|
||||
await variadic.click({ timeout: 1000 })
|
||||
await variadic.hover({ timeout: 10000 })
|
||||
await variadic.click({ timeout: 10000 })
|
||||
expect(await blueprintPage.node.locator("ueb-pin").all()).toHaveLength(testData.pins + 1)
|
||||
await variadic.blur()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user