提交 1d7bcc42 编写于 作者: W wangjinxin613

test: 兼容自动化测试 webview 模式

上级 3a160a17
......@@ -2,7 +2,7 @@ const PAGE_PATH = "/pages/API/element-takesnapshot/element-takesnapshot";
describe("element-takesnapshot", () => {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1) {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1 || process.env.UNI_AUTOMATOR_APP_WEBVIEW == 'true') {
it('dummyTest', () => {
expect(1).toBe(1)
})
......
const PAGE_PATH = '/pages/API/get-app-authorize-setting/get-app-authorize-setting'
describe('ExtApi-GetAppAuthorizeSetting', () => {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1) {
describe('ExtApi-GetAppAuthorizeSetting', () => {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1 || process.env.UNI_AUTOMATOR_APP_WEBVIEW == 'true') {
it('dummyTest', () => {
expect(1).toBe(1)
})
......
......@@ -2,7 +2,7 @@ const PAGE_PATH = '/pages/API/get-file-system-manager/get-file-system-manager'
describe('ExtApi-FileManagerTest', () => {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1) {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1 || process.env.UNI_AUTOMATOR_APP_WEBVIEW == 'true') {
it('dummyTest', () => {
expect(1).toBe(1)
})
......
const PAGE_PATH = '/pages/API/get-system-setting/get-system-setting'
describe('ExtApi-GetSystemSetting', () => {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1) {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1 || process.env.UNI_AUTOMATOR_APP_WEBVIEW == 'true') {
it('web', () => {
expect(1).toBe(1)
})
......
describe('component-native-nested-scroll-body', () => {
describe('component-native-nested-scroll-body', () => {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1 || process.env.UNI_AUTOMATOR_APP_WEBVIEW == 'true') {
it('dummyTest', () => {
expect(1).toBe(1)
})
return
}
let page
beforeAll(async () => {
//打开lnested-scroll-body测试页
......
describe('component-native-nested-scroll-header', () => {
if (process.env.uniTestPlatformInfo.indexOf('web') > -1 || process.env.UNI_AUTOMATOR_APP_WEBVIEW == 'true') {
it('dummyTest', () => {
expect(1).toBe(1)
})
return
}
let page
beforeAll(async () => {
beforeAll(async () => {
//打开lnested-scroll-header测试页
page = await program.reLaunch('/pages/component/nested-scroll-header/nested-scroll-header')
await page.waitFor(600)
})
it('check_nested-scroll-header', async () => {
const image = await program.screenshot();
expect(image).toMatchImageSnapshot();
})
it('check_nested-scroll-header', async () => {
const image = await program.screenshot();
expect(image).toMatchImageSnapshot();
})
})
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册