diff --git a/test/playwright/README.md b/test/playwright/README.md index 40b9ecc099..4433c4b453 100644 --- a/test/playwright/README.md +++ b/test/playwright/README.md @@ -2,8 +2,6 @@ 插件名称 `Playwright Test for VSCode` -### 测试平台安装软件包 @steedos/k6-test - ### 配置环境变量 - `ROOT_URL` 需要测试的平台地址 diff --git a/test/playwright/tests/login.insert.record.spec.js b/test/playwright/tests/login.insert.record.spec.js deleted file mode 100644 index 8576f610bd..0000000000 --- a/test/playwright/tests/login.insert.record.spec.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * @Author: baozhoutao@steedos.com - * @Date: 2024-03-28 13:32:36 - * @LastEditors: baozhoutao@steedos.com - * @LastEditTime: 2024-03-28 17:17:44 - * @Description: - */ - -import { test, expect } from '@playwright/test'; -const path =require('path'); -delete process.env.ROOT_URL -delete process.env.LOGIN_NAME -delete process.env.PASSWORD -require('dotenv-flow').config({path: path.join(__dirname, '..')}); - -test('test', async ({ page }) => { - await page.goto(process.env.ROOT_URL); - await page.goto(`${process.env.ROOT_URL}/accounts/a/#/login?redirect_uri=/`); - await page.getByPlaceholder('手机或邮箱').click(); - await page.getByPlaceholder('手机或邮箱').fill(process.env.LOGIN_NAME); - await page.getByPlaceholder('手机或邮箱').press('Tab'); - await page.getByPlaceholder('密码').fill(process.env.PASSWORD || '123456'); - await page.getByRole('button', { name: '提交' }).click(); - await page.getByRole('button', { name: '新建' }).click(); - await page.locator('input[name="name"]').click(); - await page.locator('input[name="name"]').fill(''); - await page.locator('input[name="name"]').press('CapsLock'); - await page.locator('input[name="name"]').fill('测试'); - await page.getByRole('button', { name: '保存', exact: true }).click(); - - await page.waitForTimeout(3000); - - await expect(page).toHaveScreenshot('login.insert.record.png'); -}); \ No newline at end of file diff --git a/test/playwright/tests/login.insert.record.spec.js-snapshots/login-insert-record-chromium-darwin.png b/test/playwright/tests/login.insert.record.spec.js-snapshots/login-insert-record-chromium-darwin.png deleted file mode 100644 index a1e5c4d5fa..0000000000 Binary files a/test/playwright/tests/login.insert.record.spec.js-snapshots/login-insert-record-chromium-darwin.png and /dev/null differ