提交 dbe7e931 编写于 作者: 雪洛's avatar 雪洛

test: 在web端屏蔽image cookie测试

上级 9582d44c
...@@ -20,7 +20,7 @@ describe('component-native-image', () => { ...@@ -20,7 +20,7 @@ describe('component-native-image', () => {
await page.waitFor(300); await page.waitFor(300);
expect(await page.data('loadError')).toBe(false) expect(await page.data('loadError')).toBe(false)
}) })
it('check_image_load_error', async () => { it('check_image_load_error', async () => {
await page.setData({ await page.setData({
loadError: false, loadError: false,
...@@ -30,22 +30,24 @@ describe('component-native-image', () => { ...@@ -30,22 +30,24 @@ describe('component-native-image', () => {
expect(await page.data('loadError')).toBe(true) expect(await page.data('loadError')).toBe(true)
}) })
it('check-cookie', async () => { if (process.env.uniTestPlatformInfo.startsWith('android')) {
await page.setData({ it('check-cookie', async () => {
autoTest: true, await page.setData({
setCookieImage: 'https://cdn.dcloud.net.cn/img/shadow-grey.png' autoTest: true,
}); setCookieImage: 'https://cdn.dcloud.net.cn/img/shadow-grey.png'
await page.waitFor(1000); });
await page.setData({ await page.waitFor(1000);
loadError: false, await page.setData({
verifyCookieImage: 'https://request.dcloud.net.cn/img/shadow-grey.png' loadError: false,
}); verifyCookieImage: 'https://request.dcloud.net.cn/img/shadow-grey.png'
await page.waitFor(1000); });
expect(await page.data('loadError')).toBe(false); await page.waitFor(1000);
await page.setData({ expect(await page.data('loadError')).toBe(false);
autoTest: false await page.setData({
}); autoTest: false
}) });
})
}
it('path-screenshot', async () => { it('path-screenshot', async () => {
const page = await program.navigateTo('/pages/component/image/image-path'); const page = await program.navigateTo('/pages/component/image/image-path');
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册