feat: 前端集成 Prettier 代码格式化
This commit is contained in:
@@ -43,7 +43,7 @@ test.describe('供应商管理', () => {
|
||||
await page.waitForSelector('.t-select__dropdown', { state: 'hidden', timeout: 3000 })
|
||||
|
||||
await inputs.saveBtn.click()
|
||||
|
||||
|
||||
await expect(page.locator('.t-table__body').getByText('Test Provider')).toBeVisible({ timeout: 10000 })
|
||||
})
|
||||
|
||||
@@ -60,8 +60,10 @@ test.describe('供应商管理', () => {
|
||||
await page.waitForSelector('.t-select__dropdown', { timeout: 3000 })
|
||||
await page.locator('.t-select__dropdown .t-select-option').first().click()
|
||||
await page.waitForSelector('.t-select__dropdown', { state: 'hidden', timeout: 3000 })
|
||||
|
||||
const responsePromise = page.waitForResponse(resp => resp.url().includes('/api/providers') && resp.request().method() === 'POST')
|
||||
|
||||
const responsePromise = page.waitForResponse(
|
||||
(resp) => resp.url().includes('/api/providers') && resp.request().method() === 'POST'
|
||||
)
|
||||
await inputs.saveBtn.click()
|
||||
await responsePromise
|
||||
await expect(page.locator('.t-table__body').getByText('Before Edit')).toBeVisible({ timeout: 5000 })
|
||||
@@ -72,8 +74,10 @@ test.describe('供应商管理', () => {
|
||||
const editInputs = formInputs(page)
|
||||
await editInputs.name.clear()
|
||||
await editInputs.name.fill('After Edit')
|
||||
|
||||
const updateResponsePromise = page.waitForResponse(resp => resp.url().includes('/api/providers') && resp.request().method() === 'PUT')
|
||||
|
||||
const updateResponsePromise = page.waitForResponse(
|
||||
(resp) => resp.url().includes('/api/providers') && resp.request().method() === 'PUT'
|
||||
)
|
||||
await editInputs.saveBtn.click()
|
||||
await updateResponsePromise
|
||||
await expect(page.locator('.t-table__body').getByText('After Edit')).toBeVisible({ timeout: 5000 })
|
||||
|
||||
Reference in New Issue
Block a user